Received: from magus.postgresql.org (magus.postgresql.org [87.238.57.229]) by mail.postgresql.org (Postfix) with ESMTP id E86B82B4151 for ; Sun, 20 May 2012 14:54:13 -0300 (ADT) Received: from mail.pcorp.us ([204.51.253.130]) by magus.postgresql.org with smtp (Exim 4.72) (envelope-from ) id 1SWAKY-0004Ev-Mi for pgsql-bugs@postgresql.org; Sun, 20 May 2012 17:54:12 +0000 Received: from D ([50.78.240.110]) by mail.pcorp.us ; Sun, 20 May 2012 13:53:45 -0400 From: "Paragon Corporation" To: "'Tom Lane'" Cc: , "'Paul Ramsey'" , "'Mark Cave-Ayland'" , "'strk'" , "'Chris Hodgson'" References: <5301.1337534868@sss.pgh.pa.us> In-Reply-To: <5301.1337534868@sss.pgh.pa.us> Subject: Re: BUG #6640: pg_dump does not always dump data of tables marked as editable in extension Date: Sun, 20 May 2012 13:53:25 -0400 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 Thread-Index: Ac02reCovzx1oP0MSCKRwap29i2n0QAANgTg X-MimeOLE: Produced By Microsoft MimeOLE V6.1.7601.17609 X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201205/118 X-Sequence-Number: 33089 Tom, Okay understood. We had planned to do something along this line of having a where condition for the extension or putting the custom spatial_ref_sys in a separate table but hand't decided which way to go. So that will take care of the handling custom records issue. So I guess the more major issue is a won't fix on both sides since a user will not be able to backup custom records without backing up the whole database. I don't see any option in 9.1 or 9.2 pg_dump to explicitly backup an extension and even backing up the schema an extension is installed in doesn't seem to do the trick. I would have expected backing up the schema an extension is installed in would backup the extension. Is that expected behavior that it doesn't? Thanks, Regina > -----Original Message----- > From: Tom Lane [mailto:tgl@sss.pgh.pa.us] > Sent: Sunday, May 20, 2012 1:28 PM > To: lr@pcorp.us > Cc: pgsql-bugs@postgresql.org > Subject: Re: [BUGS] BUG #6640: pg_dump does not always dump > data of tables marked as editable in extension > > lr@pcorp.us writes: > > This seems to be only an issue if a user individually chooses to > > backup a table marked as editable in an extension, but > works fine if > > full backup is chosen. > > AFAICT this is a misunderstanding of the intended behavior of > extension configuration tables. The data in them will be > dumped when, and only when, the extension itself is included > in the dump. Moreover, if you have a mixture of > extension-provided and user-provided data in the table, as > seems to be the case here, you really need to take measures > to keep those separate so that you can dump only the > user-provided entries. > This is not a "fire and forget" type of feature, it requires > nontrivial effort on the part of the extension author to make > it useful. Please see > http://www.postgresql.org/docs/9.1/static/extend-extensions.ht ml#AEN51978 > > regards, tom lane >