summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Eisentraut <peter@eisentraut.org>2022-08-12 08:17:30 +0200
committerPeter Eisentraut <peter@eisentraut.org>2022-08-12 08:52:45 +0200
commite1878cf94134429bf951b41ed523363c2fa2d6b4 (patch)
treeff42280d76a8b153f6d71511888e7a9870abbc9c
parent15014b82320347981b7f25fdad0ccb08870337cb (diff)
Fix _outConstraint() for "identity" constraints
The set of fields printed by _outConstraint() in the CONSTR_IDENTITY case didn't match the set of fields actually used in that case. (The code was probably uncarefully copied from the CONSTR_DEFAULT case.) Fix that by using the right set of fields. Since there is no read support for this node type, this is really just for debugging output right now, so it doesn't affect anything important.
-rw-r--r--src/backend/nodes/outfuncs.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/backend/nodes/outfuncs.c b/src/backend/nodes/outfuncs.c
index 6d89001498e..4b2c3e43062 100644
--- a/src/backend/nodes/outfuncs.c
+++ b/src/backend/nodes/outfuncs.c
@@ -3868,8 +3868,7 @@ _outConstraint(StringInfo str, const Constraint *node)
case CONSTR_IDENTITY:
appendStringInfoString(str, "IDENTITY");
- WRITE_NODE_FIELD(raw_expr);
- WRITE_STRING_FIELD(cooked_expr);
+ WRITE_NODE_FIELD(options);
WRITE_CHAR_FIELD(generated_when);
break;