Case Insenstive Matching
Posted in 1996
Topics: Connectivity: ESQL/C, 4GL & Embedded SQL
Is there a simple way to do a case insensitive search in Informix /ESQLC?
I'd like to be able to search for *chimp* for example, and come up with
all matches that include nboth chimp and Chimp and CHIMP. The two ways
I've determined so far, neither of which I like:
1. Convert my search into *[Cc]{Hh][Ii][Mm][Pp]* which seems like an
awful lot of work for such a common request
2. Add an extra column to my database that contains the search field in
all upper case. I woulfd then search this column but return the original
column. This would not be the most relational way to design a database
(although my data is realtively flat for my simple application.)
There isn't an uppercase function hiding anywhere that would let me
do a
select * from photos where ucase(caption) matches *CHIMP*
is there? If there is could you please point me at the appropriate
section of the Informix reference manual. Email responses much appreciated.
--
Elliotte Rusty Harold
elharo@shock.njit.edu
elliotte@blackstar.com