Re: Character subscripts in SQL/SPL
Posted in 1997
Jeff Larsen <larsen@qec.com> wrote: :Since you can't use variables for character subscripts in SQL or :stored procedures, how do you do any useful string manipulation? You don't. :I am trying to write a stored procedure to calculate the soundex :value of a character string. It's going to get ugly if :I can't loop through the characters. Is SQL really this lame? No not SQL, but Informix SPL is for this purpose. You might want to check out the metaphone algorithm at http://www.iiug.org (there is a soundex as well, but metaphone is normaly much better). The negative thing is you have to include such a routine in all applications that update the table in question instead of having it in the database. 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