[GENERAL] Problem with PL/pgSQL

2001-02-24 Thread Hans-Jürgen Schönig
What is wrong with the following function? CREATE FUNCTION logfunc2 (text) RETURNS int AS ' DECLARE text ALIAS FOR $1; BEGIN SELECT length(text); RETURN ''3''; END; ' LANGUAGE 'plpgsql'; I get the following error: ERROR: U

[GENERAL] Problem with PL/pgSQL in 7.03

2001-01-25 Thread Dmitry Chernikov
Hi I migrated from version 6.5 to 7.03 My function (see below) doesn't work in 7.03, but it works in 6.5 .   CREATE FUNCTION "projects_update_function" ( ) RETURNS opaque AS ' begin   if TG_OP=''UPDATE'' then NEW."Last Modify":=''now''; return NEW;   end if; end;' LANGUAGE 'plpgsql