Re: pg_dump feature

From: David Fetter <david(at)fetter(dot)org>
To: Naz <lists(at)mrnaz(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: pg_dump feature
Date: 2008-09-22 05:32:35
Message-ID: 20080922053235.GK19216@fetter.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Sep 22, 2008 at 03:25:35AM +1000, Naz wrote:
> Hi all,
> I brought this up a few years ago in the 7.4 days, and since there
> is still no satisfactory solution to this I thought I'd raise it
> again. When dumping a schema, it is often necessary to dump the
> tables separately to the constraints and other non-structural
> metadata. The most obvious use case for this is when updating a
> schema for a database.
>
> Assume I have a database named "production" and one named "testing".

Good so far.

> Lets now say that I have decided that "testing" is correct and the
> app is ready to work with it, and I now want to put the data from
> "production" into the schema from "testing".

That's where you should have been storing all the SQL transformations
(DDL, DCL and DML) in your source code management system and testing
said transformations to make sure they all fit inside one transaction :)

> I hope someone agrees with me :)

The above is what I've seen work. Other schemes...not so well.

> السلام عليكم

And upon you, peace.
David.
--
David Fetter <david(at)fetter(dot)org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david(dot)fetter(at)gmail(dot)com

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Dave Page 2008-09-22 07:20:35 Re: Where to Host Project
Previous Message Joe Conway 2008-09-22 04:21:35 Re: [patch] fix dblink security hole