Re: Pg_restore and dump -- General question - Mailing list pgsql-general

From salah jubeh
Subject Re: Pg_restore and dump -- General question
Date
Msg-id 599442.84987.qm@web161514.mail.bf1.yahoo.com
Whole thread Raw
In response to Re: Pg_restore and dump -- General question  (Scott Marlowe <scott.marlowe@gmail.com>)
List pgsql-general

 

Thank you all, I will take that in account
 



From: Scott Marlowe <scott.marlowe@gmail.com>
To: Howard Cole <howardnews@selestial.com>
Cc: salah jubeh <s_jubeh@yahoo.com>; pgsql-general@postgresql.org
Sent: Mon, April 4, 2011 1:44:28 PM
Subject: Re: [GENERAL] Pg_restore and dump -- General question

On Mon, Apr 4, 2011 at 5:40 AM, Howard Cole <howardnews@selestial.com> wrote:
> On 04/04/2011 11:47 AM, salah jubeh wrote:
>
> What will happen if
>
> 1. dropped table a
> 2. insert data on b and the other relations
> 3. restore table a and it's dependency (table b).
>
> Simple advice would be to create a script on an offline system for testing -
> when you are happy with the results - do it on the online system - after
> making a backup of course! Anything else would be suicidal.

Agreed. AND on the production system first take a backup and THEN run
the drop cascade inside a transaction in case it does crazy things you
didn't foresee.

begin;
drop object yada cascade;

then rollback if things get too scary.

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Merged Model for libpq
Next
From: Adrian Klaver
Date:
Subject: Re: Large Object permissions lost in transfer