Click here to Skip to main content
15,920,438 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i am getting zero results when executing this sql query while i have one row contains "Unable" word!!!


SELECT * FROM rccdb.dbo.SEARCH WHERE PROB_TITLE LIKE '%Unable'


Does anyone knows the solution?
Posted

This will return a result if the PROB_TITLE field has an entry that ends with "Unable". If you're looking for the word "Unable" anywhere in the field, you'll have to change your spec to '%Unable%'.
 
Share this answer
 
Comments
shadi_abushaar 30-Dec-10 14:33pm    
Thank youuuu soooo much... oops...
Hi Shadi,


Use this -
SELECT * FROM rccdb.dbo.SEARCH WHERE PROB_TITLE LIKE '%Unable%'

What is different is wild card (%) at the end also. It should bring result if "Unable" word is there any where.

Thank you,
Srini Oleti.
 
Share this answer
 
Comments
shadi_abushaar 30-Dec-10 14:35pm    
Thank you Sri Oleti...
Try SELECT * FROM rccdb.dbo.SEARCH WHERE PROB_TITLE = '%Unable'

or
SELECT * FROM rccdb.dbo.SEARCH WHERE PROB_TITLE LIKE 'Unable'
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900