Re: SQL feature requests

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: SQL feature requests
Дата
Msg-id 8435.1187886657@sss.pgh.pa.us
обсуждение исходный текст
Ответ на SQL feature requests  ("Ben Tilly" <btilly@gmail.com>)
Ответы Re: SQL feature requests
Список pgsql-hackers
"Ben Tilly" <btilly@gmail.com> writes:
> ... But then I need this (possibly
> empty) list to have a valid group by statement at the end.  In Oracle
> I used to just write it like this:

>   SELECT ...
>   GROUP BY $possible_term_1
>     $possible_term_2
>     $possible_term_3
>     'end of possible groupings'

FWIW, that will work if you write it as
'end of possible groupings'::text

I'm disinclined to accept it as-is because (a) it's highly likely to be
a mistake, and (b) there's no principled way to assign a datatype to the
expression, if we are to interpret it as an expression.

Basically anything but an unadorned constant will work there.
        regards, tom lane


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

Предыдущее
От: "Ben Tilly"
Дата:
Сообщение: Re: SQL feature requests
Следующее
От: Gregory Stark
Дата:
Сообщение: Re: SQL feature requests