Re: error-free disabling of individual child partition

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: "Jim C(dot) Nasby" <jnasby(at)pervasive(dot)com>
Cc: April Lorenzen <outboundindex(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: error-free disabling of individual child partition
Date: 2006-05-22 19:28:39
Message-ID: 447210E7.10904@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Jim C. Nasby wrote:
>
> BEGIN;
> -- Don't do the drop right now, because it might take awhile
> ALTER TABLE tablename RENAME TO delete_tablename;
> ALTER TABLE temporary_tablename RENAME TO tablename;
> COMMIT;
> DROP delete_tablename;
>
>

What if there are dependencies? Might be better to have a view, which
everything depends on, and change the view definition from one table to
another back and forth.

cheers

andrew

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jim C. Nasby 2006-05-22 19:33:34 Re: Porting MSSQL to PGSQL (Was: [OT] MySQL is bad, but THIS
Previous Message Martijn van Oosterhout 2006-05-22 19:26:30 Update on sort-compression stuff