pg_dump: Refactor code that constructs ALTER ... OWNER TO commands
Peter Eisentraut <peter.eisentraut@enterprisedb.com>
From: Peter Eisentraut <peter.eisentraut@enterprisedb.com>
To: pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2022-10-24T09:54:28Z
Lists: pgsql-hackers
Attachments
- 0001-pg_dump-Refactor-code-that-constructs-ALTER-.-OWNER-.patch (text/plain) patch 0001
Avoid having to list all the possible object types twice. Instead, only _getObjectDescription() needs to know about specific object types. It communicates back to _printTocEntry() whether an owner is to be set. In passing, remove the logic to use ALTER TABLE to set the owner of views and sequences. This is no longer necessary. Furthermore, if pg_dump doesn't recognize the object type, this is now a fatal error, not a warning.
Commits
-
pg_dump: Refactor code that constructs ALTER ... OWNER TO commands
- 3655b46aa0b8 16.0 landed