From: Andrew Sullivan <ajs@crankycanuck.ca>
To: pgsql-sql@postgresql.org
Subject: Re: Move table between schemas
Date: Tue, 16 Nov 2004 06:05:38 -0500
Message-ID: <20041116110538.GA15247@phlogiston.dyndns.org> (raw)
In-Reply-To: <20041116100234.635fcd7e@kingfisher.intern.logi-track.com>
References: <20041116100234.635fcd7e@kingfisher.intern.logi-track.com>
On Tue, Nov 16, 2004 at 10:02:34AM +0100, Markus Schaber wrote:
> Hello,
>
> Is there an easy way to move a table to another schema in PostgreSQL 7.4?
>
> ALTER TABLE and ALTER SCHEMA don't have this options.
CREATE TABLE newschema.newtable AS SELECT * FROM oldschema.oldtable
oughta work.
A
--
Andrew Sullivan | ajs@crankycanuck.ca
When my information changes, I alter my conclusions. What do you do sir?
--attr. John Maynard Keynes
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: ajs@crankycanuck.ca
Subject: Re: Move table between schemas
In-Reply-To: <20041116110538.GA15247@phlogiston.dyndns.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox