mirror of https://github.com/citusdata/citus.git
Removes support for postfix operators from ruleutils_14.c
Relevant PG commit: 1ed6b895634ce0dc5fd4bd040e87252b32182cbatalha_pg14_support
parent
90baf6018b
commit
62d3cecb06
|
@ -6171,35 +6171,14 @@ get_oper_expr(OpExpr *expr, deparse_context *context)
|
|||
}
|
||||
else
|
||||
{
|
||||
/* unary operator --- but which side? */
|
||||
/* prefix operator */
|
||||
Node *arg = (Node *) linitial(args);
|
||||
HeapTuple tp;
|
||||
Form_pg_operator optup;
|
||||
|
||||
tp = SearchSysCache1(OPEROID, ObjectIdGetDatum(opno));
|
||||
if (!HeapTupleIsValid(tp))
|
||||
elog(ERROR, "cache lookup failed for operator %u", opno);
|
||||
optup = (Form_pg_operator) GETSTRUCT(tp);
|
||||
switch (optup->oprkind)
|
||||
{
|
||||
case 'l':
|
||||
appendStringInfo(buf, "%s ",
|
||||
generate_operator_name(opno,
|
||||
InvalidOid,
|
||||
exprType(arg)));
|
||||
get_rule_expr_paren(arg, context, true, (Node *) expr);
|
||||
break;
|
||||
case 'r':
|
||||
get_rule_expr_paren(arg, context, true, (Node *) expr);
|
||||
appendStringInfo(buf, " %s",
|
||||
generate_operator_name(opno,
|
||||
exprType(arg),
|
||||
InvalidOid));
|
||||
break;
|
||||
default:
|
||||
elog(ERROR, "bogus oprkind: %d", optup->oprkind);
|
||||
}
|
||||
ReleaseSysCache(tp);
|
||||
appendStringInfo(buf, "%s ",
|
||||
generate_operator_name(opno,
|
||||
InvalidOid,
|
||||
exprType(arg)));
|
||||
get_rule_expr_paren(arg, context, true, (Node *) expr);
|
||||
}
|
||||
if (!PRETTY_PAREN(context))
|
||||
appendStringInfoChar(buf, ')');
|
||||
|
|
Loading…
Reference in New Issue