Re: Aggregate ORDER BY patch

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Aggregate ORDER BY patch
Дата
Msg-id 2480.1258124519@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Aggregate ORDER BY patch  (Peter Eisentraut <peter_e@gmx.net>)
Ответы Re: Aggregate ORDER BY patch
Список pgsql-hackers
Peter Eisentraut <peter_e@gmx.net> writes:
> On fre, 2009-11-13 at 03:16 +0000, Andrew Gierth wrote:
>> Caveat: as discussed earlier, this patch changes the behaviour of
>> array_agg(DISTINCT x) when applied to NULL inputs. Formerly, the NULLs
>> were unconditionally skipped; now, they are treated just like DISTINCT
>> or GROUP BY normally do.

> The right answer to that should be in the SQL standard.

It's not.  The standard defines the behavior of certain specific
aggregates; it doesn't provide general rules that would apply to
user-defined aggregates.  In particular, all the standard aggregates
are strict and so they just ignore nulls anyhow.  The proposed change
would only affect the behavior of aggregates with non-strict transition
functions.
        regards, tom lane


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

Предыдущее
От: Andrew Chernow
Дата:
Сообщение: Re: Listen / Notify rewrite
Следующее
От: Andrew Dunstan
Дата:
Сообщение: Re: plperl and inline functions -- first draft