Wrox Home  
Search P2P Archive for: Go

  Return to Index  

interbase thread: Case insensitive search


Message #1 by "Jennie Frizelle" <jfrizelle@d...> on Tue, 5 Nov 2002 16:27:11
Hi,
I'm displaying a textbox to allow the user to search my Interbase database 
by entering 1 or more characters and returning all records that match 
(supposedly!).

I have a few customers whose names begin with 'Michael'. However if I 
enter 'mich' or 'MICH' in the textbox, it doesn't return any records - I 
have to enter 'Mich' exactly as it appears in the database. 

Can anyone tell me how to convert my search to upper or lower case? I've 
tried things like 

oCMD = New OdbcCommand("SELECT * FROM CUSTOMER WHERE LOWER(CUSTOMER_NAME) 
LIKE LOWER('" & txtCustName.Text & "%') ORDER BY CUSTOMER_NAME", oConn)

but these give me error messages (I'm creating an asp.net page - maybe I'm 
posting to the wrong list here??)

Thanks for any help.
Jennie.

  Return to Index