pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Richard Huxton <dev@archonet.com>
To: Fabio Ferrero <nutella@inwind.it>
Cc: pgsql-sql@postgresql.org
Subject: Re: duplicate table in two databases
Date: Mon, 16 Aug 2004 09:01:31 +0100
Message-ID: <412069DB.107@archonet.com> (raw)
In-Reply-To: <411B73D0.3080208@inwind.it>
References: <411B73D0.3080208@inwind.it>

Fabio Ferrero wrote:
> I use postgres 7.2.1 (debian woody) and PHP.
> 
> I've two databases (foo and bar for example) with the same table (ie. 
> stamps).
> 
> It's possible with a single query transfer the data from the stamps 
> table in db foo to the stamps table in db bar?

You might want to look in the contrib/ folder of the source distribution 
(or the equivalent in your packaged installation for "dblink". Haven't 
used it myself, but it can certainly do what you want here.

-- 
   Richard Huxton
   Archonet Ltd



view thread (2+ messages)

Message-ID: <412069DB.107@archonet.com>
Permalink:  ../412069DB.107@archonet.com/
Also on:    postgresql.org/message-id/412069DB.107@archonet.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-sql@postgresql.org
  Cc: dev@archonet.com, nutella@inwind.it
  Subject: Re: duplicate table in two databases
  In-Reply-To: <412069DB.107@archonet.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