Hello this is correct SELECT col1 FROM table WHERE col2=var INTO res; Regards Pavel Stehule 2011/1/14 tbazadaykin <tbazadaykin@xxxxxxxxx>: > CREATE OR REPLACE FUNCTION "scheme"."function" (var varchar) RETURNS varchar AS > DECLARE > Âres varchar; > BEGIN > Â/* Which is correct? This: */ > > Â/*Or this:*/ > ÂSELECT col1 FROM table WHERE col2=quote_literal(var) INTO res; > ÂRETURN res; > END; > > -- > Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) > To make changes to your subscription: > http://www.postgresql.org/mailpref/pgsql-general > -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general