From: Tom Lane <tgl@sss.pgh.pa.us>
To: phb.emaj@free.fr
Cc: pgsql-bugs@postgresql.org
Subject: Re: BUG #6682: pg_dump and sequence values of serial columns for extension configuration tables
Date: Sat, 09 Jun 2012 18:20:18 -0400
Message-ID: <5379.1339280418@sss.pgh.pa.us> (raw)
In-Reply-To: <E1SdFbu-0006NI-A6@wrigleys.postgresql.org>
References: <E1SdFbu-0006NI-A6@wrigleys.postgresql.org>
phb.emaj@free.fr writes:
> When a table is registered as an extension configuration table and contains
> a serial column, the current value of the sequence associated to this serial
> column is not dumped by pg_dump.
I think the way to make that happen is to also register the sequence as
a configuration table of the extension. It's not clear to me that that
should happen by default; it would depend a lot on how the extension
designer intends to manage modifications of the table.
> echo "--> And sequences cannot be registered as 'content to be dumped'"
> $PGBIN/psql -ac "select
> pg_catalog.pg_extension_config_dump('tbl1_col1_seq','');"
This test proves nothing of the kind. Please read the error message:
ERROR: pg_extension_config_dump() can only be called from an SQL script executed by CREATE EXTENSION
You have to do it in the extension's script.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: tgl@sss.pgh.pa.us, phb.emaj@free.fr
Subject: Re: BUG #6682: pg_dump and sequence values of serial columns for extension configuration tables
In-Reply-To: <5379.1339280418@sss.pgh.pa.us>
References: <E1SdFbu-0006NI-A6@wrigleys.postgresql.org> <5379.1339280418@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox