Re: ANY_VALUE aggregate

Поиск
Список
Период
Сортировка
От Vik Fearing
Тема Re: ANY_VALUE aggregate
Дата
Msg-id 7e0b78af-c8db-4a09-7612-08d35f84fcf3@postgresfriends.org
обсуждение исходный текст
Ответ на Re: ANY_VALUE aggregate  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 1/18/23 16:55, Tom Lane wrote:
> Peter Eisentraut <peter.eisentraut@enterprisedb.com> writes:
>> On 05.12.22 21:18, Vik Fearing wrote:
>>> On 12/5/22 15:57, Vik Fearing wrote:
>>>> The SQL:2023 Standard defines a new aggregate named ANY_VALUE.  It
>>>> returns an implementation-dependent (i.e. non-deterministic) value
>>>> from the rows in its group.
> 
>> Since the transition function is declared strict, null values don't need
>> to be checked.
> 
> Hmm, but should it be strict?  That means that what it's returning
> is *not* "any value" but "any non-null value".  What does the draft
> spec have to say about that?

It falls into the same category as AVG() etc.  That is, nulls are 
removed before calculation.
-- 
Vik Fearing




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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: ANY_VALUE aggregate
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Improve GetConfigOptionValues function