Router planner: bail on volatile functions in CTEs

pull/2778/head
Philip Dubé 2019-06-26 10:29:59 +02:00
parent 5c62f9935a
commit db7fdb1854
1 changed files with 10 additions and 1 deletions

View File

@ -615,7 +615,16 @@ ModifyQuerySupported(Query *queryTree, Query *originalQuery, bool multiShardQuer
if (cteQuery->hasForUpdate)
{
return DeferredError(ERRCODE_FEATURE_NOT_SUPPORTED,
"Router planner doesn't support SELECT FOR UPDATE in common table expressions.",
"Router planner doesn't support SELECT FOR UPDATE"
" in common table expressions.",
NULL, NULL);
}
if (FindNodeCheck((Node *) cteQuery, CitusIsVolatileFunction))
{
return DeferredError(ERRCODE_FEATURE_NOT_SUPPORTED,
"Router planner doesn't support VOLATILE functions"
" in common table expressions.",
NULL, NULL);
}