Re: temp table existence - Mailing list pgsql-sql

From aklaver@comcast.net (Adrian Klaver)
Subject Re: temp table existence
Date
Msg-id 122920072225.1629.4776C95300035CAA0000065D22007456729D0A900E04050E@comcast.net
Whole thread Raw
In response to temp table existence  ("Marcin Krawczyk" <jankes.mk@gmail.com>)
List pgsql-sql
------------- Original message ----------------------
From: "Marcin Krawczyk" <jankes.mk@gmail.com>
> Hi all. Is there a way to determine the existence of a TEMP
> TABLE? I need to check i it exists before I create it. Doing simple
> check on pg_class or pg_tables is
> not enough because there may be other such tables created in other sessions.
> Or maybe anyone knows the identification (apart from 'others') of error to
> trap it with EXCEPTION clause?

select  *  from temp_table limit 1;
Trap error 42P01 Undefined table.

--
Adrian Klaver
aklaver@comcast.net

 -


pgsql-sql by date:

Previous
From: "Pavel Stehule"
Date:
Subject: Re: temp table existence
Next
From: Erik Jones
Date:
Subject: Re: temp table existence