I'm trying to detect the existence of a temp table in a function for
that connection.
So,
Connection 1:
Create table foo (i int);
Connection 2:
select * from pg_class where relname = 'foo'
returns the table from connection 1, however I need to know if there's a
temp table foo for connection 2 not connection 1. Each row in pg_class
is associated with a namespace, so I'm looking for something like:
select * from pg_class where relname = 'foo' and relnamespace = ???
-Michael
Michael Fuhr wrote:
>On Thu, Feb 03, 2005 at 08:16:30PM -0500, Michael Guerin wrote:
>
>
>> Is there a way to find out the namespace id (relnamespace) for your
>>connection?
>>
>>
>
>It's not clear what you're trying to do. Are you looking for
>current_schema()? Or maybe one of the other system information
>functions?
>
>http://www.postgresql.org/docs/8.0/static/functions-info.html
>
>
>