Re: copying tables

From: ERIC Lawson - x52010 <eric(at)bioeng(dot)washington(dot)edu>
To: Robert Kernell <kernell(at)sundog(dot)larc(dot)nasa(dot)gov>
Cc: pg-novice list <pgsql-novice(at)postgresql(dot)org>
Subject: Re: copying tables
Date: 2001-02-21 17:05:23
Message-ID: Pine.LNX.4.21.0102210858580.355-100000@arwen.bioeng.washington.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-novice

Check out pg_dump: basically, this works --

pg_dump -t tablename olddbname > table.out

followed by

psql -d newdbname < table.out

or

psql -d newdbname -f table.out

On Tue, 20 Feb 2001, Robert Kernell wrote:

> Hi. I am trying to copy tables. I want to copy a table in one database to a
> table in another database. The tables are identical. Here is to code and the
> error when using DBI. Can I just use postgresQL somehow?
>
> Thank you.
>
> Bob Kernell
> Research Scientist
> Analytical Services & Materials, Inc.
> NASA Atmospheric Sciences Competency
> Radiation and Aerolsols Branch
> email: r(dot)w(dot)kernell(at)larc(dot)nasa(dot)gov
> tel: 757-827-4631
>

--

James Eric Lawson
Research Publications Editor III
National Simulation Resource

eric(at)bioeng(dot)washington(dot)edu

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Everyday language is a part of the human organism and is no less
complicated than it. - Ludwig Wittgenstein (1889-1951) [Tractatus
Logico-Philosophicus, 1921]

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Brent R. Matzelle 2001-02-21 17:06:35 Re: Re: Printing PostgreSQL reports
Previous Message David Wheeler 2001-02-21 16:48:16 Re: Grant on Database?

Browse pgsql-novice by date

  From Date Subject
Next Message Mike Friesen 2001-02-21 19:15:26 General Inquiry
Previous Message ERIC Lawson - x52010 2001-02-21 16:50:22 Re: changing column data types