Subject RE: [firebird-support] Re: soundex
Author Si Carter
> -----Original Message-----
> Thank you I will give it a try and report back
>

No problems, fwiw I used the following proc to update a soundex column I
created, in the employee table:

SET TERM ## ;

CREATE OR ALTER PROCEDURE UPDATE_SNDEX_VALUE
AS
DECLARE VARIABLE vEmpNo SMALLINT;
DECLARE VARIABLE vLastName VARCHAR(37);
DECLARE VARIABLE vSndex VARCHAR(5);
BEGIN
FOR
SELECT EMP_NO, LAST_NAME
FROM EMPLOYEE
INTO :vEmpNo, :vLastName
DO
BEGIN
EXECUTE PROCEDURE SOUNDEX(cast(vLastName as varchar(25)))
RETURNING_VALUES vSndex;

UPDATE EMPLOYEE
SET LAST_SOUNDEX = :vSndex
WHERE EMP_NO = :vEmpNo;
END
END ##

SET TERM ; ##

Rgds

Si Carter
http://www.fbtalk.net/ - Web Based Firebird Forum
http://www.tectsoft.net/ - Homepage