Re: [HACKERS] ORDER BY 1 COLLATE

2011-04-18 Thread Kevin Grittner
Andrew Dunstan wrote: > It's likely to be used by SQL generators if nothing else, and I've > been known to use it as a very convenient shorthand. It would seem > to me like quite a strange inconsistency to allow order by n with > some qualifiers but not others. That's pretty much how I feel.

Re: [HACKERS] ORDER BY 1 COLLATE

2011-04-18 Thread Dann Corbit
> -Original Message- > From: pgsql-hackers-ow...@postgresql.org [mailto:pgsql-hackers- > ow...@postgresql.org] On Behalf Of Andrew Dunstan > Sent: Monday, April 18, 2011 1:43 PM > To: Tom Lane > Cc: Peter Eisentraut; pgsql-hackers > Subject: Re: [HACKERS] ORDER BY 1

Re: [HACKERS] ORDER BY 1 COLLATE

2011-04-18 Thread Andrew Dunstan
On 04/18/2011 04:20 PM, Tom Lane wrote: Peter Eisentraut writes: This came from a review by Noah Misch a great while ago: test=> SELECT b FROM foo ORDER BY 1 COLLATE "C"; ERROR: 42804: collations are not supported by type integer According to SQL92, this should be supported. Do we want to

Re: [HACKERS] ORDER BY 1 COLLATE

2011-04-18 Thread Tom Lane
Peter Eisentraut writes: > This came from a review by Noah Misch a great while ago: > test=> SELECT b FROM foo ORDER BY 1 COLLATE "C"; > ERROR: 42804: collations are not supported by type integer > According to SQL92, this should be supported. Do we want to bother? It > doesn't look hard to fi

[HACKERS] ORDER BY 1 COLLATE

2011-04-18 Thread Peter Eisentraut
This came from a review by Noah Misch a great while ago: test=> SELECT b FROM foo ORDER BY 1 COLLATE "C"; ERROR: 42804: collations are not supported by type integer According to SQL92, this should be supported. Do we want to bother? It doesn't look hard to fix, so it's really only a question o