Wednesday, November 24, 2021

Like clause in sql server

SELECT *

FROM test1

WHERE id LIKE '%1%'

----------------------------******************---------------------------------

SELECT *

FROM test1

WHERE id LIKE '%1%'

AND ID LIKE '%2%'

OR ID LIKE '%3%'

(Screenshot of table structure below)

reference:- https://stackoverflow.com/questions/14290857/sql-select-where-field-contains-words



No comments:

Post a Comment