Search Postgresql Archives

Re: transfering tables into other schema

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Feb 17, 2009 at 12:34 AM, Ivan Sergio Borgonovo
<mail@xxxxxxxxxxxxxxx> wrote:
> I've around 150-200 tables in the same schema.
> Some of them have pk/fk relationships and are referenced into
> functions (~20).
>
> One of them is surely referenced by most of those 20 and it is the
> largest.
>
> I'd like to move all the 200 tables to a new schema and leave that
> one in the public schema.
>
> The DB size accordingly to select pg_size_pretty(pg_database_size is
> 1.5Gb
>
> I can afford 1 day down (WE).

Have you tried

ALTER TABLE name SET SCHEMA new_schema;

???

Should just work with no real downtime.

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux