From dcf3902f02db09a067f066bd46bc3ad354f323b9 Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Tue, 10 Mar 2009 22:09:26 +0000 Subject: Make SubPlan nodes carry the result's typmod as well as datatype OID. This is for consistency with the (relatively) recent addition of typmod to SubLink. An example of why it's a good idea is to be seen in the recent "failed to locate grouping columns" bug, which wouldn't have happened if a SubPlan exposed the same typmod info as the SubLink it was derived from. This could be back-patched, since it doesn't affect any on-disk data format, but for the moment it doesn't seem necessary to do so. --- src/backend/nodes/outfuncs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/backend/nodes/outfuncs.c') diff --git a/src/backend/nodes/outfuncs.c b/src/backend/nodes/outfuncs.c index c68dea8a2ce..d64f0ad0426 100644 --- a/src/backend/nodes/outfuncs.c +++ b/src/backend/nodes/outfuncs.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/nodes/outfuncs.c,v 1.353 2009/02/25 03:30:37 tgl Exp $ + * $PostgreSQL: pgsql/src/backend/nodes/outfuncs.c,v 1.354 2009/03/10 22:09:25 tgl Exp $ * * NOTES * Every node type that can appear in stored rules' parsetrees *must* @@ -957,6 +957,7 @@ _outSubPlan(StringInfo str, SubPlan *node) WRITE_NODE_FIELD(paramIds); WRITE_INT_FIELD(plan_id); WRITE_OID_FIELD(firstColType); + WRITE_INT_FIELD(firstColTypmod); WRITE_BOOL_FIELD(useHashTable); WRITE_BOOL_FIELD(unknownEqFalse); WRITE_NODE_FIELD(setParam); -- cgit v1.2.3