Make SubPlan nodes carry the result's typmod as well as datatype OID. This is
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 10 Mar 2009 22:09:26 +0000 (22:09 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 10 Mar 2009 22:09:26 +0000 (22:09 +0000)
commit244a5f98cea3be7a9b8e31f41014bca4704f56cb
tree8da250f8e2253de8945667c44c4a7895cd17bbb2
parenta210053dd0d84010041e744acf0811b7c893f7cc
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/copyfuncs.c
src/backend/nodes/equalfuncs.c
src/backend/nodes/nodeFuncs.c
src/backend/nodes/outfuncs.c
src/backend/optimizer/plan/subselect.c
src/include/nodes/primnodes.h