SQL Select "like" operator

cirollo

Active Member
Licensed User
Longtime User
I'm wondering if is possible to use the "like" operator in a SQL query

For example, if I need only the records that start with given word,....

in sql should be (if i remember right):

select * from mytable where myfield like "sta"....

results: STAr, STAtement, STAring,.....

and in case "abc" is inside the record??? in sql I use %sta or %sta%

results: popSTAr, gangSTA, rockSTAr,......

this should be done in b4android????
 

henry1311

Member
Licensed User
Longtime User
yes...
... field_name LIKE 'STA%'
... field_name LIKE '%STA'
... field_name LIKE '%STA%'

The library also works with SQL b4android
Attention to single or double quote!

ciao
enrico
 
Last edited:
Upvote 0
Top