Re: Delete temp tables - Mailing list pgsql-general

From Bruce Momjian
Subject Re: Delete temp tables
Date
Msg-id 200010251515.LAA03828@candle.pha.pa.us
Whole thread Raw
In response to Re: Delete temp tables  ("Vilson farias" <vilson.farias@digitro.com.br>)
List pgsql-general
[ Charset ISO-8859-1 unsupported, converting... ]
> : In short: if you want to delete a table there is one and only one
> : safe method to do it: DROP TABLE.  The key difference between a temp
> : table and a regular table is that the DROP will be done for you
> : automatically when you disconnect.
>
> Now why?
> relatorio=#  DROP TABLE "pg_temp.1823.17";
> ERROR:  class "pg_temp.1823.17" is a system catalog
>
> I really need to erase these tables, because they are not been auto-removed
> after my application crashes. I have more than 100 zombie temp tables in my
> system. What are the system tables that I need to remove temp tables
> information?

That is strange that they were not auto-deleted.  If they don't exist in
pg_class anymore, just 'rm' the physical files.

--
  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

pgsql-general by date:

Previous
From: KuroiNeko
Date:
Subject: Re: Using pgsql to archive e-mail
Next
From: Tom Lane
Date:
Subject: Re: Problems with genetic optimizer