Re: UNION and ORDER BY ... IS NULL ASC

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: UNION and ORDER BY ... IS NULL ASC
Дата
Msg-id 11805.1049516260@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: UNION and ORDER BY ... IS NULL ASC  (Josh Berkus <josh@agliodbs.com>)
Список pgsql-sql
Josh Berkus <josh@agliodbs.com> writes:
>> ERROR:  ORDER BY on a UNION/INTERSECT/EXCEPT result must be on one of 
>> the result columns

> I do believe that this is per the SQL spec; UNIONs may only be sorted on the 
> output columns.

Right.  We extend the SQL spec for ORDER BY on simple selects, but we
have not gotten around to doing so for ORDER BY on set-operation
results.  You can only sort by unadorned output columns.

Patches to improve this are welcome ;-)
        regards, tom lane



В списке pgsql-sql по дате отправления:

Предыдущее
От: Josh Berkus
Дата:
Сообщение: Re: UNION and ORDER BY ... IS NULL ASC
Следующее
От: "CIC mail"
Дата:
Сообщение: unscribe