Re: Need help in copying a table from one database to other

From: "A(dot) Kretschmer" <andreas(dot)kretschmer(at)schollglas(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Need help in copying a table from one database to other
Date: 2009-09-04 08:35:24
Message-ID: 20090904083524.GD8068@a-kretschmer.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

In response to Rekha Ravi Pai :
> Hi,
> I want to copy a table say employeedetails from employee
> database to library database. Can you help me giving the
> detailed steps to do this.

pg_dump -t <insert the table-name> <insert the source-db> | psql <insert destination db>

In you case:

pg_dump -t employeedetails employee | psql library

Regards, Andreas
--
Andreas Kretschmer
Kontakt: Heynitz: 035242/47150, D1: 0160/7141639 (mehr: -> Header)

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Juan Backson 2009-09-04 09:42:31 strange error occurs when adding index
Previous Message Nickolay 2009-09-04 08:26:35 Re: easy task: concurrent select-updates