diff options
Diffstat (limited to 'src/backend/utils/adt/ruleutils.c')
-rw-r--r-- | src/backend/utils/adt/ruleutils.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/backend/utils/adt/ruleutils.c b/src/backend/utils/adt/ruleutils.c index 23000281bbe..493ba924a49 100644 --- a/src/backend/utils/adt/ruleutils.c +++ b/src/backend/utils/adt/ruleutils.c @@ -8715,8 +8715,10 @@ get_rule_expr(Node *node, deparse_context *context, castNode(PartitionRangeDatum, lfirst(cell)); appendStringInfoString(buf, sep); - if (datum->infinite) - appendStringInfoString(buf, "UNBOUNDED"); + if (datum->kind == PARTITION_RANGE_DATUM_MINVALUE) + appendStringInfoString(buf, "MINVALUE"); + else if (datum->kind == PARTITION_RANGE_DATUM_MAXVALUE) + appendStringInfoString(buf, "MAXVALUE"); else { Const *val = castNode(Const, datum->value); @@ -8733,8 +8735,10 @@ get_rule_expr(Node *node, deparse_context *context, castNode(PartitionRangeDatum, lfirst(cell)); appendStringInfoString(buf, sep); - if (datum->infinite) - appendStringInfoString(buf, "UNBOUNDED"); + if (datum->kind == PARTITION_RANGE_DATUM_MINVALUE) + appendStringInfoString(buf, "MINVALUE"); + else if (datum->kind == PARTITION_RANGE_DATUM_MAXVALUE) + appendStringInfoString(buf, "MAXVALUE"); else { Const *val = castNode(Const, datum->value); |