Re: aliases for temp tables.... - Mailing list pgsql-general

From Tom Lane
Subject Re: aliases for temp tables....
Date
Msg-id 11045.982474594@sss.pgh.pa.us
Whole thread Raw
In response to aliases for temp tables....  (Alfonso Peniche <alfonso@iteso.mx>)
Responses Re: aliases for temp tables....  (Bruce Momjian <pgman@candle.pha.pa.us>)
List pgsql-general
Alfonso Peniche <alfonso@iteso.mx> writes:
> I've been looking everywhere and I can't find this:
> Everytime I create a temp table (Thanx Tom) within a procedure, a table
> named like pg_temp.###.# is created (I know this is MY temp table). How
> can I know the name (or alias) for this table so that I can, later on,
> check if it already exists.

AFAIK there is no way to retrieve the temp-table name mapping from the
backend.  Sorry ...

When we implement schemas (hopefully for 7.2) perhaps it will be
possible to reimplement temp tables in a slightly less klugy way,
so that this sort of problem goes away.

            regards, tom lane

pgsql-general by date:

Previous
From: "Dave Cramer"
Date:
Subject: Re: PHP style Annotated Manual
Next
From: Bruce Momjian
Date:
Subject: Re: aliases for temp tables....