Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 select

Author  Topic 

DENIZ3E
Yak Posting Veteran

56 Posts

Posted - 2005-12-26 : 06:43:40
hý,
ý want to search character " ' " ýn my table

select code from TABLE WHERE CODE LIKE '''

but ERRORRR
Server: Msg 105, Level 15, State 1, Line 1
Unclosed quotation mark before the character string ''
'.
Server: Msg 170, Level 15, State 1, Line 1
Line 1: Incorrect syntax near ''
'.

shallu1_gupta
Constraint Violating Yak Guru

394 Posts

Posted - 2005-12-26 : 06:49:01
Hi,
use two "''" instead of "'"
Go to Top of Page

shallu1_gupta
Constraint Violating Yak Guru

394 Posts

Posted - 2005-12-26 : 06:50:04
try this
select code from TABLE WHERE CODE LIKE ''''
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2005-12-26 : 07:46:10
or

Select columns from yourTable
where charindex('''',code,1)>0


Madhivanan

Failing to plan is Planning to fail
Go to Top of Page
   

- Advertisement -