SQL Trick : How to Escape wild characters in SQL?

preview_player
Показать описание

Комментарии
Автор

Like statement is case insensitive.. So if you want to match capital letters, use the collate or Binary keyword..ofcourse u need to escape the _ which is dependent on the type of Dbms used..

aaaba_empire
Автор

select * from wlid where name like 'j__%' escape '_'

when we apply the following query it will be give the accurate solution

prasadchowdary
Автор

There is an ESCAPE clause in the SQL server you can use.

vishvajeetdeshmukh
Автор

This ahould work something like this 'J[_]%'

ksm