Re: case insensitive order by
Posted in 1996
Daniel Wright <danwright@bigfoot.com> wrote: :SaTriGuy wrote: :> :> Universal Server (lev 9.0) allows a UDR (user defined routine) to be used :> within :> the where clause. Additional, an index can be defined to be the output of :> such a :> routine. That is, it is possible to build an index of all uppercase :> characters, and :> to search on uppercase. Also, it is possible to create an 'equality' :> logic within :> this UDR which causes prefixes such as Mac, MAC, Mc, etc. to be considered :> equal. Thus it is very easy to allow a search of McDonald to consider all :> of the :> various ways of spelling Mc to be considered the same. :> :> For case insesitive searches, the systax would be: :> :> Select * from name where upper(name) = "JONES"; :> :> For the index the syntax would be: :> Create index namidx on name (upper(name)); :> :> Madison Pruet :It sounds as if you can basically write a small function to be called by :a where clause. Is that correct? Not only in the where clause. As I understand it such a function can be used basically anywhere you can use a column name. As in the examples above in create index, and it will also work in your select list. : Is it a stored procedure? It's a user defined function implemented in a DataBlade and written in C (or possibly C++ as well?). Informix have also announced that such functions will be possible to implement in Java. Someone at Informix Norway have written a small DataBlade and says it's simple to do. Nils.Myklebust@idg.no NM Data AS, P.O.Box 9090 Gronland, N-0133 Oslo, Norway My opinions are those of my company The Informix FAQ is at http://www.iiug.org