Re: Temporary table visibility

Поиск
Список
Период
Сортировка
От James Croft
Тема Re: Temporary table visibility
Дата
Msg-id 3C91F9B7-398C-464F-A5F1-C6A790DC1CC7@lumison.net
обсуждение исходный текст
Ответ на Re: Temporary table visibility  (Jaime Casanova <systemguards@gmail.com>)
Ответы Re: Temporary table visibility  (Jaime Casanova <systemguards@gmail.com>)
Список pgsql-general
On 25 Jan 2006, at 14:17, Jaime Casanova wrote:

>> How can I determine what temporary tables exist in my session,
>> bearing in mind that other sessions contain temp tables using the
>> same names?
>>
>
> just the ones you have created in your session, temporary tables in
> other sessions are invisible to you...


Thanks Jaime but that's not really what I meant.

I know that if a session creates a temporary table it is only visible
to that session. I'm not doing a good job of explaining this but
basically given the following results...

test=> select relname, relnamespace, reltype from pg_class where
relname = 'session_data';
    relname    | relnamespace | reltype
--------------+--------------+----------
session_data |         2200 | 16114367
session_data |     16120903 | 16314010
session_data |     16120709 | 16314030
session_data |     16122659 | 16314133
session_data |     16123201 | 16314285
session_data |     16124398 | 16315049
session_data |        16767 | 16315527
session_data |     16120382 | 16315818
session_data |     16125558 | 16315816
session_data |     16114413 | 16316810
session_data |     16127654 | 16317471
session_data |     16114683 | 16317551
session_data |     16118447 | 16317563
session_data |     15035529 | 16317579
(14 rows)

How can I determine if one of the above relations is a temporary
table in the current session (one of them, the first in ns 2200, is a
normal permanent table)?


Thanks,
James



--

This email and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to whom they are addressed.
If you have received this email in error please notify the sender. Any
offers or quotation of service are subject to formal specification.
Errors and omissions excepted.  Please note that any views or opinions
presented in this email are solely those of the author and do not
necessarily represent those of Lumison, nplusone or lightershade ltd.
Finally, the recipient should check this email and any attachments for the
presence of viruses.  Lumison, nplusone and lightershade ltd accepts no
liability for any damage caused by any virus transmitted by this email.

--
--
Virus scanned by Lumison.

В списке pgsql-general по дате отправления:

Предыдущее
От: andrew
Дата:
Сообщение: Re: user defined function
Следующее
От: Bricklen Anderson
Дата:
Сообщение: Re: Shared Database across multiple servers using OCFS2