Re: Odd error when using UNION and COLLATE - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: Odd error when using UNION and COLLATE
Date
Msg-id 20160720220617.GJ24559@momjian.us
Whole thread Raw
In response to Re: Odd error when using UNION and COLLATE  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Wed, Jul 20, 2016 at 06:03:08PM -0400, Tom Lane wrote:
> Greg Stark <stark@mit.edu> writes:
> > But I think I agree that it's surprising that the collate clause isn't
> > working in the ORDER BY on a column produced by a UNION. Certainly
> > that's where people usually want to put it.
> 
> See this ancient comment in transformSetOperationStmt:
> 
>      * For now, we don't support resjunk sort clauses on the output of a
>      * setOperation tree --- you can only use the SQL92-spec options of
>      * selecting an output column by name or number.  Enforce by checking that
>      * transformSortClause doesn't add any items to tlist.
> 
> Perhaps sometime we ought to make an effort to relax that.

Oh, I didn't see that above the error block.

--  Bruce Momjian  <bruce@momjian.us>        http://momjian.us EnterpriseDB
http://enterprisedb.com

+ As you are, so once was I. As I am, so you will be. +
+                     Ancient Roman grave inscription +



pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Odd error when using UNION and COLLATE
Next
From: Petr Jelinek
Date:
Subject: Re: Design for In-Core Logical Replication