Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 2 of 2 total
Thread Finding a string regardless of case
Mon, Jun 5 2006 5:24 PMPermanent Link

Jerry Blumenthal
How do I search for a string regardless of case?  The following code
will find 'abc' or 'ABC' but not 'Abc' unless that is exactly how it is
entered in the edit box.

sql.add('WHERE (((Z4Items.Title LIKE "%'+ SSS + '%"))');
   sql.add('OR ((Z4Items.Title LIKE "%' + uppercase (SSS) + '%")))');

Using D4 and DBIsam 2.12 and a horse and a buggy.

Jerry
Mon, Jun 5 2006 6:36 PMPermanent Link

"Jose Eduardo Helminsky"
Jerry

I don't know if I understood but...

Sql.Clear;
Sql.Add('select * from table where upper(field) like '%'+
AnsiUpperCase(Edit1.Text)+'%');
Open;

Eduardo

Image