pgsql: Clean up collation processing in prepunion.c.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Clean up collation processing in prepunion.c.
Date: 2011-04-16 20:40:54
Message-ID: E1QBCIY-0002U9-CV@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Clean up collation processing in prepunion.c.

This area was a few bricks shy of a load, and badly under-commented too.
We have to ensure that the generated targetlist entries for a set-operation
node expose the correct collation for each entry, since higher-level
processing expects the tlist to reflect the true ordering of the plan's
output.

This hackery wouldn't be necessary if SortGroupClause carried collation
info ... but making it do so would inject more pain in the parser than
would be saved here. Still, we might want to rethink that sometime.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/121f49a00e432ee9cfad7270d99504350cd1015f

Modified Files
--------------
src/backend/optimizer/prep/prepjointree.c | 2 +-
src/backend/optimizer/prep/prepunion.c | 131 +++++++++++++++++++++--------
src/backend/optimizer/util/tlist.c | 34 ++++++++
src/include/optimizer/tlist.h | 1 +
4 files changed, 132 insertions(+), 36 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2011-04-16 21:26:58 pgsql: Simplify reindex_relation's API.
Previous Message Andrew Dunstan 2011-04-16 19:07:39 Re: [COMMITTERS] pgsql: Rename pg_regress option --multibyte to --encoding