X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id D48F7D1B349 for ; Tue, 13 Jul 2004 15:03:46 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 78705-06 for ; Tue, 13 Jul 2004 18:03:39 +0000 (GMT) Received: from tht.net (vista.tht.net [216.126.88.2]) by svr1.postgresql.org (Postfix) with ESMTP id DE75AD1B33F for ; Tue, 13 Jul 2004 15:03:37 -0300 (ADT) Received: from [134.22.68.4] (dyn-68-4.tor.dsl.tht.net [134.22.68.4]) by tht.net (Postfix) with ESMTP id DA72276A1F; Tue, 13 Jul 2004 14:03:40 -0400 (EDT) Subject: Re: Constraint->function dependency and dump in 7.3 From: Rod Taylor To: =?iso-8859-2?Q?SZ=DBCS_G=E1bor?= Cc: pgsql-sql@postgresql.org In-Reply-To: <022401c46900$b85c26e0$0403a8c0@fejleszt4> References: <00a001c4680b$f14c60a0$0403a8c0@fejleszt4> <1089636713.58812.37.camel@jester> <01f401c468f6$90905c80$0403a8c0@fejleszt4> <1089739239.48027.64.camel@jester> <022401c46900$b85c26e0$0403a8c0@fejleszt4> Content-Type: text/plain; charset=iso-8859-2 Message-Id: <1089741816.48027.89.camel@jester> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.6 Date: Tue, 13 Jul 2004 14:03:37 -0400 Content-Transfer-Encoding: 8bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200407/84 X-Sequence-Number: 18336 On Tue, 2004-07-13 at 13:42, SZÛCS Gábor wrote: > Dear Rod, > > Thanks. It'll be a pain to have two versions between the prod and devel > servers, but I'll forward this info to the chief. You can make this part easier on yourself. Dump the structure from production and migrate it to devel (fix the dump file). Keep this file. From now on when applying changes to production, keep the structural changes applied as a separate SQL file (numbers work well). When building a new box to duplicate production: 1. Apply all patches in order for i in `ls *.sql` ; do cat $i | psql test_db ; done 2. Do a data dump of production and restore that to the testing area pg_dump --data-only prod_db | psql test_db Now you don't need to worry about whether the production schema will or will not dump properly, since you can reproduce that using external files.