Why can't I use windowing functions over ordered aggregates?

Поиск
Список
Период
Сортировка
От Josh Berkus
Тема Why can't I use windowing functions over ordered aggregates?
Дата
Msg-id 51C3AD31.2080504@agliodbs.com
обсуждение исходный текст
Ответы Re: Why can't I use windowing functions over ordered aggregates?  (Cédric Villemain <cedric@2ndquadrant.com>)
Список pgsql-hackers
Hackers,

So, I can create a custom aggregate "first" and do this:

SELECT first(val order by ts desc) ...

And I can do this:

SELECT first_value(val) OVER (order by ts desc)

... but I can't do this:

SELECT first_value(val order by ts desc)

... even though under the hood, it's the exact same operation.

-- 
Josh Berkus
PostgreSQL Experts Inc.
http://pgexperts.com



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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: changeset generation v5-01 - Patches & git tree
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: [PATCH] Exorcise "zero-dimensional" arrays (Was: Re: Should array_length() Return NULL)