Re: bug in PLPGSQL
От | Kovacs Zoltan |
---|---|
Тема | Re: bug in PLPGSQL |
Дата | |
Msg-id | Pine.LNX.4.21.0105141148540.1153-100000@pc10.radnoti-szeged.sulinet.hu обсуждение исходный текст |
Ответ на | Re: \c connects as another user instead I want in psql (Jan Wieck <JanWieck@Yahoo.com>) |
Ответы |
Re: Re: bug in PLPGSQL
|
Список | pgsql-hackers |
There are SELECT INTO statements which work properly. Here is an example which closes the backend: CREATE FUNCTION plpgsql_call_handler ( ) RETURNS opaque AS '/usr/local/pgsql-7.1.1/lib/plpgsql.so' LANGUAGE 'C'; CREATE TRUSTED PROCEDURAL LANGUAGE 'plpgsql' HANDLER plpgsql_call_handler LANCOMPILER 'PL/pgSQL'; create table foo(x int4, y int4); create function bugtest(int4) returns int4 as ' declare _x int4; _y int4; begin select into _x,_y x, y from foo where x = $1 limit 1; return x; end; ' language 'plpgsql'; select bugtest(5); If the WHERE clause doesn't contain any input parameters (i.e. $1), I don't get into any trouble. Zoltan -- Kov\'acs, Zolt\'an kovacsz@pc10.radnoti-szeged.sulinet.hu http://www.math.u-szeged.hu/~kovzol ftp://pc10.radnoti-szeged.sulinet.hu/home/kovacsz
В списке pgsql-hackers по дате отправления: