From: Scott Ribe <scott_ribe@elevated-dev.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #18405: flaw in dump of inherited/dropped constraints
Date: Mon, 25 Mar 2024 10:16:11 -0600
Message-ID: <866537D5-2EF9-4559-B4C6-AF16191A0D9E@elevated-dev.com> (raw)
In-Reply-To: <2497244.1711383069@sss.pgh.pa.us>
References: <18405-4ce10e802e8d3174@postgresql.org>
<2497244.1711383069@sss.pgh.pa.us>
> thanks to Alvaro's work to treat NOT NULL the same way we've long
> treated more general CHECK constraints. So there's no need to do
> anything in v17, and I think changing the behavior in released
> branches would draw more complaints than plaudits. (Also, if pg_dump
> did try harder to duplicate this situation, the result would likely be
> that the dump would fail to load into v17+.)
I'd call that an acceptable resolution. My main concern is dump/restore not being able to dump & restore an existing database, and this v17 change fixes this case. (For background, this odd inheritance wasn't a deliberate design, it was a (supposedly temporary) workaround for a client bug.)
>> ... So it looks like prior to 16, plain dumps had this
>> problem, but custom format dumps did not.
>
> Given the way pg_dump works, that's pretty hard to believe: you
> should get bitwise the same result from pg_dump to text versus
> pg_dump -Fc | pg_restore. Can you provide a self-contained test
> showing a case where it doesn't?
I will re-run tests when I get a bit of time--it is possible I confused versions or schemas somewhere along the line of switching back and forth.
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: scott_ribe@elevated-dev.com, tgl@sss.pgh.pa.us
Subject: Re: BUG #18405: flaw in dump of inherited/dropped constraints
In-Reply-To: <866537D5-2EF9-4559-B4C6-AF16191A0D9E@elevated-dev.com>
References: <18405-4ce10e802e8d3174@postgresql.org> <2497244.1711383069@sss.pgh.pa.us> <866537D5-2EF9-4559-B4C6-AF16191A0D9E@elevated-dev.com>
* 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