Re: Character subscripts in SQL/SPL
Posted in 1997
Art S. Kagel — — source: Informix-list mailing list archive (1991-1998)
Jeff Larsen wrote: > > Since you can't use variables for character subscripts in SQL or > stored procedures, how do you do any useful string manipulation? > > 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? Yes it is. Blame IBM. I saw a Soundex Stored Procedure written by Art Taylor (Informix Support) and he had to repeat the code for each character in the column. He was able to make it general enough to handle columns of length <= to a fixed value. Really nasty, really long, really slow. It was the only way to do this though. Art S. Kagel