mirror of https://github.com/citusdata/citus.git
Handle makeDefElem changes
makeDefElem now requires the token location, but simply passing -1 to signify "unknown" is sufficient.pull/1439/head
parent
3c507e7399
commit
caaaa2c9f7
|
@ -288,7 +288,15 @@ LoadTuplesIntoTupleStore(CitusScanState *citusScanState, Job *workerJob)
|
||||||
|
|
||||||
if (BinaryMasterCopyFormat)
|
if (BinaryMasterCopyFormat)
|
||||||
{
|
{
|
||||||
DefElem *copyOption = makeDefElem("format", (Node *) makeString("binary"));
|
DefElem *copyOption = NULL;
|
||||||
|
|
||||||
|
#if (PG_VERSION_NUM >= 100000)
|
||||||
|
int location = -1; /* "unknown" token location */
|
||||||
|
copyOption = makeDefElem("format", (Node *) makeString("binary"), location);
|
||||||
|
#else
|
||||||
|
copyOption = makeDefElem("format", (Node *) makeString("binary"));
|
||||||
|
#endif
|
||||||
|
|
||||||
copyOptions = lappend(copyOptions, copyOption);
|
copyOptions = lappend(copyOptions, copyOption);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1404,6 +1404,11 @@ SetDefElemArg(AlterSeqStmt *statement, const char *name, Node *arg)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if (PG_VERSION_NUM >= 100000)
|
||||||
|
defElem = makeDefElem((char *) name, arg, -1);
|
||||||
|
#else
|
||||||
defElem = makeDefElem((char *) name, arg);
|
defElem = makeDefElem((char *) name, arg);
|
||||||
|
#endif
|
||||||
|
|
||||||
statement->options = lappend(statement->options, defElem);
|
statement->options = lappend(statement->options, defElem);
|
||||||
}
|
}
|
||||||
|
|
|
@ -510,7 +510,12 @@ CopyTaskFilesFromDirectory(StringInfo schemaName, StringInfo relationName,
|
||||||
copyStatement = CopyStatement(relation, fullFilename->data);
|
copyStatement = CopyStatement(relation, fullFilename->data);
|
||||||
if (BinaryWorkerCopyFormat)
|
if (BinaryWorkerCopyFormat)
|
||||||
{
|
{
|
||||||
|
#if (PG_VERSION_NUM >= 100000)
|
||||||
|
DefElem *copyOption = makeDefElem("format", (Node *) makeString("binary"),
|
||||||
|
-1);
|
||||||
|
#else
|
||||||
DefElem *copyOption = makeDefElem("format", (Node *) makeString("binary"));
|
DefElem *copyOption = makeDefElem("format", (Node *) makeString("binary"));
|
||||||
|
#endif
|
||||||
copyStatement->options = list_make1(copyOption);
|
copyStatement->options = list_make1(copyOption);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue