PL/pgSQL bug?

From: Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp>
To: pgsql-hackers(at)postgresql(dot)org
Subject: PL/pgSQL bug?
Date: 2001-09-30 12:13:02
Message-ID: 20010930211302X.t-ishii@sra.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

In the attached script, second call to test1() causes error:

select test1();
test1
-------
0
(1 row)

select test1();
psql:/home/t-ishii/tmp/aaa.sql:13: NOTICE: Error occurred while executing PL/pgSQL function test1
psql:/home/t-ishii/tmp/aaa.sql:13: NOTICE: line 5 at select into variables
psql:/home/t-ishii/tmp/aaa.sql:13: ERROR: Relation 422543 does not exist

Maybe PL/pgSQL cache problem?
--
Tatsuo Ishii
----------------------------------------------------------------------
drop function test1();
create function test1() returns int as '
declare
rec RECORD;
begin
create temp table temp_aaa (i int);
select into rec * from temp_aaa;
drop table temp_aaa;
return 0;
end;
'language 'plpgsql';
select test1();
select test1();

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Doug McNaught 2001-09-30 15:11:43 Re: Pre-forking backend
Previous Message Gavin Sherry 2001-09-30 10:12:20 Re: Pre-forking backend