title: How to search for special characters in SQL Server 2008 R2?
body: <p>I got the requirements that I have to search for special characters like the names who are having single quotes in their names <code>c'te</code></p>
  
  <p>ex: </p>
  
  <pre><code>select * from names where name like 'c'test%'
  </code></pre>
  
  <p>For this I got the solution like </p>
  
  <pre><code>select * from names where name like '%''%'
  </code></pre>
  
  <p>The above answer is useful to search  who are having single quotes in their names but my requirement is how do i search the name directly  like </p>
  
  <pre><code>select * from names where name like 'c'test%'
  </code></pre>
  
  <p>because from application side they will search for the lable last name d'tech</p>
  
  <p>Please note that we should not pass any extra quotes while searching the names </p>
  
  <p>Help on this with example will be appreciated </p>
  
  <p>Thanks in advance</p>