Re: Dump EXTENSION sequences too - Mailing list pgsql-hackers

From Robert Haas
Subject Re: Dump EXTENSION sequences too
Date
Msg-id CA+TgmoaH=sMHH22rsGwVnx+shOJJiArSyVzUeyCOQPz4n5XydQ@mail.gmail.com
Whole thread Raw
In response to Dump EXTENSION sequences too  (Gianni Ciolli <gianni.ciolli@2ndquadrant.it>)
List pgsql-hackers
On Thu, Apr 19, 2012 at 6:42 AM, Gianni Ciolli
<gianni.ciolli@2ndquadrant.it> wrote:
> currently an EXTENSION can mark some of its tables as "configuration
> tables" using pg_catalog.pg_extension_config_dump(), so that pg_dump
> "does the right thing".
>
> I think it would be useful to mark sequences too, but unfortunately it
> is not possible; hence, each time a dump is reloaded, all the
> sequences in the extension are reset to 1, causing all the related
> problems.
>
> Moreover, the error message that we get if we try to mark a sequence
> does not mention the requirement that the relation is a table. The
> "OID %u does not refer to a table" error message seems to be wrongly
> restricted to the case when get_rel_name can't find a relation.
>
> Is there any objection to the above proposal? I did a little search of
> the archives, but I couldn't find any related discussions; I apologise
> if I missed something.

Seems like a good idea to me.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: DOMAINs and CASTs
Next
From: Robert Haas
Date:
Subject: Re: Postgres install program files folder