Re: How to get schema name in which TEMPORARY table is created?

From: Christian Ullrich <chris(at)chrullrich(dot)net>
To: pgsql-admin(at)postgresql(dot)org
Subject: Re: How to get schema name in which TEMPORARY table is created?
Date: 2011-03-09 09:07:35
Message-ID: il7g0n$r4j$1@dough.gmane.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

* Gnanakumar wrote:

> We're using PostgreSQL v8.2.3.
>
> How do I get the schema name in which TEMPORARY table is created using
> "CREATE TEMP TABLE mytable ...." syntax?

SELECT nspname FROM pg_namespace WHERE oid = pg_my_temp_schema();

I don't have an 8.2.3 lying around, but git says that function is in there.

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Gnanakumar 2011-03-09 10:06:08 Advise on dropping TEMP table/schema for my use case
Previous Message Gnanakumar 2011-03-09 04:43:01 Re: How to get schema name in which TEMPORARY table is created?