Re: Dumping/restoring fails on inherited generated column
Masahiko Sawada <sawada.mshk@gmail.com>
From: Masahiko Sawada <sawada.mshk@gmail.com>
To: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Cc: Masahiko Sawada <masahiko.sawada@2ndquadrant.com>,
Tom Lane <tgl@sss.pgh.pa.us>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2020-11-06T03:55:07Z
Lists: pgsql-hackers
On Wed, Nov 4, 2020 at 4:23 AM Peter Eisentraut <peter.eisentraut@2ndquadrant.com> wrote: > > On 2020-08-27 13:30, Masahiko Sawada wrote: > > This issue is not fixed yet. I've attached the updated version patch > > and registered it to commit fest so as not to forget. Please review > > it. > > A few fixes have been committed in this thread, basically to prevent > situations that shouldn't have been allowed. > > What's left is the originally reported issue that some parts of the > regression test database are dumped incorrectly. The two proposed > patches in their most recent versions are > > https://www.postgresql.org/message-id/attachment/107447/v3-0001-pg_dump-Fix-dumping-of-inherited-generated-column.patch > (message > https://www.postgresql.org/message-id/b1c831dd-d520-5e7f-0304-0eeed39c9996%402ndquadrant.com) > > and > > https://www.postgresql.org/message-id/attachment/113487/fix_gcolumn_dump_v2.patch > (message > https://www.postgresql.org/message-id/CA%2Bfd4k6pLzrZDQsdsxcS06AwGRf1DgwOw84sFq9oXNw%2B83nB1g%40mail.gmail.com) > > Both of these result in the same change to the dump output. Both of > them have essentially the same idea. The first one adds the > conditionals during the information gathering phase of pg_dump, the > second one adds the conditionals during the output phase. > > Any further thoughts? I think the first one is better than the second (mine) because it can save the number of intermediate objects. Regards, -- Masahiko Sawada EnterpriseDB: https://www.enterprisedb.com/
Commits
-
Fix ALTER TABLE / INHERIT with generated columns
- 13ff139a2384 12.7 landed
- 64190d65f299 13.3 landed
- a970edbed306 14.0 landed
-
pg_dump: Fix dumping of inherited generated columns
- 1dd6baf78802 12.6 landed
- 1d3ce0223c6a 13.2 landed
- 0bf83648a52d 14.0 landed
-
Disallow ALTER TABLE ONLY / DROP EXPRESSION
- 539775981746 13.1 landed
- bf797a8d9768 14.0 landed
-
Fix several DDL issues of generated columns versus inheritance
- 086ffddf3656 13.0 cited