mirror of https://github.com/citusdata/citus.git
Specify column in owned sequence call
getOwnedSequences can now filter owned sequences by a specified column. Passing InvalidAttrNumber preserves the original behavior of returning all sequences owned by a specified relation.pull/1439/head
parent
b1cf59e32a
commit
b2319011fe
|
@ -498,7 +498,11 @@ GetTableCreationCommands(Oid relationId, bool includeSequenceDefaults)
|
||||||
{
|
{
|
||||||
List *tableDDLEventList = NIL;
|
List *tableDDLEventList = NIL;
|
||||||
char tableType = 0;
|
char tableType = 0;
|
||||||
|
#if (PG_VERSION_NUM >= 100000)
|
||||||
|
List *sequenceIdlist = getOwnedSequences(relationId, InvalidAttrNumber);
|
||||||
|
#else
|
||||||
List *sequenceIdlist = getOwnedSequences(relationId);
|
List *sequenceIdlist = getOwnedSequences(relationId);
|
||||||
|
#endif
|
||||||
ListCell *sequenceIdCell;
|
ListCell *sequenceIdCell;
|
||||||
char *tableSchemaDef = NULL;
|
char *tableSchemaDef = NULL;
|
||||||
char *tableColumnOptionsDef = NULL;
|
char *tableColumnOptionsDef = NULL;
|
||||||
|
|
|
@ -841,7 +841,11 @@ List *
|
||||||
SequenceDDLCommandsForTable(Oid relationId)
|
SequenceDDLCommandsForTable(Oid relationId)
|
||||||
{
|
{
|
||||||
List *sequenceDDLList = NIL;
|
List *sequenceDDLList = NIL;
|
||||||
|
#if (PG_VERSION_NUM >= 100000)
|
||||||
|
List *ownedSequences = getOwnedSequences(relationId, InvalidAttrNumber);
|
||||||
|
#else
|
||||||
List *ownedSequences = getOwnedSequences(relationId);
|
List *ownedSequences = getOwnedSequences(relationId);
|
||||||
|
#endif
|
||||||
ListCell *listCell;
|
ListCell *listCell;
|
||||||
char *ownerName = TableOwner(relationId);
|
char *ownerName = TableOwner(relationId);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue