pgsql: Do not dump identity sequences with excluded parent table

Started by Michael Paquieralmost 8 years ago1 messagescomitters
Jump to latest
#1Michael Paquier
michael@paquier.xyz

Do not dump identity sequences with excluded parent table

This commit prevents a crash of pg_dump caused by the exclusion of a
table which has identity columns, as the table would be correctly
excluded but not its identity sequence. In order to fix that, identity
sequences are excluded if the parent table is defined as such. Knowing
about such sequences has no meaning without their parent table anyway.

Reported-by: Andy Abelisto
Author: David Rowley
Reviewed-by: Peter Eisentraut, Michael Paquier
Discussion: /messages/by-id/153479393218.1316.8472285660264976457@wrigleys.postgresql.org
Backpatch-through: 10

Branch
------
REL_10_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/cb282eab1a684bb409dcb6cadbf7dd868227713d

Modified Files
--------------
src/bin/pg_dump/pg_dump.c | 16 ++++++++++++++--
1 file changed, 14 insertions(+), 2 deletions(-)