Click here to Skip to main content
15,899,679 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi experts,

How can i say that "L S Kumar" and "Kumar L S" are equal in sql ??
how can i compare these two names?

thank you
(Keerthi Kumar)
Posted

1 solution

you can use like for the same..

like '%L S%'
 
Share this answer
 
v2
Comments
Keerthi Kumar(Andar) 27-Sep-14 5:16am    
if i use like this. Kumar L S karun, such names will also come in the result set so. i don't want such out put
RossMW 27-Sep-14 6:11am    
If the data is in a text type field then you can only compare random text with some defined rule which you have not provided. Hence under these conditions solution 1 is the best method or a expansion of it like field = '%L S%' and field like '%Kumar%'.

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