pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Kevin Grittner <Kevin.Grittner@wicourts.gov>
To: pgsql-admin@postgresql.org
To: smiley2211 <smiley2211@yahoo.com>
Subject: Re: Dump & Load a database???
Date: Tue, 21 Aug 2007 09:57:39 -0500
Message-ID: <46CAB713.EE98.0025.0@wicourts.gov> (raw)
In-Reply-To: <12256258.post@talk.nabble.com>
References: <12256258.post@talk.nabble.com>

>>> On Tue, Aug 21, 2007 at  9:50 AM, in message <12256258.post@talk.nabble.com>,
smiley2211 <smiley2211@yahoo.com> wrote: 

> Do I have to DROP \ recreate and load the target database (this is what I
> currently do)?  is there a way to just do an IN PLACE load like in other
> RDBMS environments???
> 
> pg_dump proddb | gzip > proddb_082107.sql.gz
> 
> gunzip < proddb_082107.sql.gz | psql -d testdb -f -
 
You might want to consider using one or both of these pg_dump options:
 
  -c, --clean                 clean (drop) schema prior to create
  -C, --create                include commands to create database in dump
 





view thread (3+ messages)  latest in thread

Message-ID: <46CAB713.EE98.0025.0@wicourts.gov>
Permalink:  ../46CAB713.EE98.0025.0@wicourts.gov/
Also on:    postgresql.org/message-id/46CAB713.EE98.0025.0@wicourts.gov

 · 

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: Kevin.Grittner@wicourts.gov, smiley2211@yahoo.com
  Subject: Re: Dump & Load a database???
  In-Reply-To: <46CAB713.EE98.0025.0@wicourts.gov>

* 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