pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Amador Alvarez <aalvarez@d2.com>
To: pgsql-admin@postgresql.org
Subject: Re: Merging two databases
Date: Thu, 14 Jun 2012 11:34:20 -0700
Message-ID: <4FDA2EAC.3010407@d2.com> (raw)
In-Reply-To: <CAGWYGjU6NqpkKgLd+vv1sGKxiJc9FmtobxQz4eitMshR0zTmNA@mail.gmail.com>
References: <CAGWYGjU6NqpkKgLd+vv1sGKxiJc9FmtobxQz4eitMshR0zTmNA@mail.gmail.com>

Hi,
Obviously it will always depends on the constraints in your schema, but 
why do not dump the databases out and import it into a single one 
properly? Once you get the new database, it should be easy to catch up 
with the 2 databases before the switching (with statements like 
insert/update into Newdb tables ...(select from Olddb tables)).
It is up to you, this is to avoid replication settings, however using 
replication could be a good thing for future replication experiences.

A.A.



On 06/12/2012 03:23 AM, Lukasz Brodziak wrote:
> Hi there,
>
> Is there a way of merging two databases in postgresql in the way of
> differential replication? The thing is that we have two DBs with same
> schemas and we want to merge the data within them into one single
> replica. Are there any tools/ways of doing this? Of course when the
> merged db is created it will be only updated/inserted with new data
> from each of source DBs.
>



view thread (3+ messages)

Message-ID: <4FDA2EAC.3010407@d2.com>
Permalink:  ../4FDA2EAC.3010407@d2.com/
Also on:    postgresql.org/message-id/4FDA2EAC.3010407@d2.com

 · 

reply

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-admin@postgresql.org
  Cc: aalvarez@d2.com
  Subject: Re: Merging two databases
  In-Reply-To: <4FDA2EAC.3010407@d2.com>

* 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