Re: How to merge 3 databases in one database quickly - Mailing list pgsql-general

From scott.marlowe
Subject Re: How to merge 3 databases in one database quickly
Date
Msg-id Pine.LNX.4.33.0306090855090.1952-100000@css120.ihs.com
Whole thread Raw
In response to How to merge 3 databases in one database quickly  (Nagib Abi Fadel <nagib_postgres@yahoo.com>)
List pgsql-general
On Wed, 4 Jun 2003, Nagib Abi Fadel wrote:

> I'm trying to merge 3 databases in one database using pg_dump.
>
> pg_dump db1 > database.txt
> pg_dump db2 >> database.txt
> pg_dump db3 >> database.txt
>
> then i restore:
> psql database < database.txt
>
> I  had errors when trying to restore, i fixed some of them but still i
> get other kinds of error.
> What i want to know is : IS THERE ANY OTHER WAY TO MERGE THE 3
> DATABASES QUICKLY WITHOUT GETTTING ERRORS ???

What might work is putting each one into a different schema.  If you're
running 7.3 all you need to do is edit the dump files to create a
different schema for each database dump and import into that.

If you're not running 7.3.3 I'd recommend upgrading for this feature alone
for you, not to mention all the other improvements made from 7.2 to 7.3


pgsql-general by date:

Previous
From: "Brian Maguire"
Date:
Subject: Feature Suggestion/Index tuning wizard that automatically decide on indexes
Next
From: Robert Treat
Date:
Subject: Re: MySQL gets $19.5 MM