Skip to content

Commit a22d6a2

Browse files
committed
pg_dump: Add missing relkind case
Checking for RELKIND_MATVIEW was forgotten in guessConstraintInheritance(). This isn't a live problem, since it is checked in flagInhTables() which relkinds can have parents, and those entries will have numParents==0 after that. But after discussion it was felt that this place should be kept consistent with flagInhTables() and flagInhAttrs(). Reviewed-by: Michael Paquier <michael@paquier.xyz> Discussion: https://www.postgresql.org/message-id/flat/a574c8f1-9c84-93ad-a9e5-65233d6fc00f@enterprisedb.com
1 parent f2c52ee commit a22d6a2

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/bin/pg_dump/pg_dump.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2762,9 +2762,10 @@ guessConstraintInheritance(TableInfo *tblinfo, int numTables)
27622762
TableInfo **parents;
27632763
TableInfo *parent;
27642764

2765-
/* Sequences and views never have parents */
2765+
/* Some kinds never have parents */
27662766
if (tbinfo->relkind == RELKIND_SEQUENCE ||
2767-
tbinfo->relkind == RELKIND_VIEW)
2767+
tbinfo->relkind == RELKIND_VIEW ||
2768+
tbinfo->relkind == RELKIND_MATVIEW)
27682769
continue;
27692770

27702771
/* Don't bother computing anything for non-target tables, either */

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy