diff --git a/src/backend/distributed/master/master_node_protocol.c b/src/backend/distributed/master/master_node_protocol.c index b075518e3..5a82fa8bd 100644 --- a/src/backend/distributed/master/master_node_protocol.c +++ b/src/backend/distributed/master/master_node_protocol.c @@ -498,7 +498,11 @@ GetTableCreationCommands(Oid relationId, bool includeSequenceDefaults) { List *tableDDLEventList = NIL; char tableType = 0; +#if (PG_VERSION_NUM >= 100000) + List *sequenceIdlist = getOwnedSequences(relationId, InvalidAttrNumber); +#else List *sequenceIdlist = getOwnedSequences(relationId); +#endif ListCell *sequenceIdCell; char *tableSchemaDef = NULL; char *tableColumnOptionsDef = NULL; diff --git a/src/backend/distributed/metadata/metadata_sync.c b/src/backend/distributed/metadata/metadata_sync.c index 0c4788c2e..c2626446e 100644 --- a/src/backend/distributed/metadata/metadata_sync.c +++ b/src/backend/distributed/metadata/metadata_sync.c @@ -841,7 +841,11 @@ List * SequenceDDLCommandsForTable(Oid relationId) { List *sequenceDDLList = NIL; +#if (PG_VERSION_NUM >= 100000) + List *ownedSequences = getOwnedSequences(relationId, InvalidAttrNumber); +#else List *ownedSequences = getOwnedSequences(relationId); +#endif ListCell *listCell; char *ownerName = TableOwner(relationId);