Received: from candle.pha.pa.us (candle.navpoint.com [162.33.245.46]) by mail.postgresql.org (8.11.3/8.11.1) with ESMTP id f2OGidw69599 for ; Sat, 24 Mar 2001 11:44:39 -0500 (EST) (envelope-from pgman@candle.pha.pa.us) Received: (from pgman@localhost) by candle.pha.pa.us (8.9.0/8.9.0) id LAA17614; Sat, 24 Mar 2001 11:44:18 -0500 (EST) From: Bruce Momjian Message-Id: <200103241644.LAA17614@candle.pha.pa.us> Subject: Re: how do I check if a temporary table exists? In-Reply-To: <20010324124215.A94771A61@druid.net> "from D'Arcy J.M. Cain at Mar 24, 2001 07:42:15 am" To: "D'Arcy J.M. Cain" Date: Sat, 24 Mar 2001 11:44:18 -0500 (EST) CC: datactrl , pgsql-sql@postgresql.org, roelof.sondaar@scania.com X-Mailer: ELM [version 2.4ME+ PL77 (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII X-Archive-Number: 200103/479 X-Sequence-Number: 2150 Multiple backends can create temp tables with the same name and each person will see their own version. > Thus spake datactrl > > How do I check if a temporary table exists? Searching pg_tables with a > > temporary table name we chose always fails. > > What do you mean? You know that it exists because you just created it > and the create succeeded. Can you describe a situation where you need > to know about a temp table and don't already know? > > It can't go into the pg_tables table because then it would be visible > to other processes. Are you perhaps misunderstanding temp tables? You > cannot see them except from the process that created them. > > -- > D'Arcy J.M. Cain | Democracy is three wolves > http://www.druid.net/darcy/ | and a sheep voting on > +1 416 425 1212 (DoD#0082) (eNTP) | what's for dinner. > > ---------------------------(end of broadcast)--------------------------- > TIP 4: Don't 'kill -9' the postmaster > -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 853-3000 + If your life is a hard drive, | 830 Blythe Avenue + Christ can be your backup. | Drexel Hill, Pennsylvania 19026