Re: creating a temp table in a function

From: Andreas 'ads' Scherbaum <adsmail(at)wars-nicht(dot)de>
To: pgsql-general(at)postgresql(dot)org
Cc: rod(at)iol(dot)ie
Subject: Re: creating a temp table in a function
Date: 2008-04-04 20:53:34
Message-ID: 20080404225334.5fe6eb10@iridium.wars-nicht.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Fri, 04 Apr 2008 21:22:17 +0100 Raymond O'Donnell wrote:

> On 04/04/2008 20:47, Andreas 'ads' Scherbaum wrote:
>
> >> I have a function that creates a temp table and drops it on commit. If
> >> I run the function twice in the same psql interactive session, I get an
> >> error. If I run it twice in two different psql sessions (using the -c
> >> flag), I get no error. Is this expected behavior? If so, why?
> >
> > Create a query in a text string and run the query with EXECUTE.
>
> Wasn't this fixed in 8.3? - Is it not the case that you no longer have
> to handle temp tables in plpgsql functions via EXECUTE?

Uhm, every day you learn something new.

Thanks for updating me, guys.

Kind regards

--
Andreas 'ads' Scherbaum
German PostgreSQL User Group
European PostgreSQL User Group - Board of Directors

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Gregory Stark 2008-04-04 21:00:17 Re: modules
Previous Message Terry Lee Tucker 2008-04-04 20:51:08 Re: Conversion to 8.3