Re: Wrong aggregate result when sorting by a NULL value
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Ondřej Bouda <obouda@email.cz>
Cc: Andres Freund <andres@anarazel.de>, pgsql-bugs@postgresql.org
Date: 2018-11-02T15:34:46Z
Lists: pgsql-bugs
I wrote:
> =?UTF-8?Q?Ond=c5=99ej_Bouda?= <obouda@email.cz> writes:
>> the following seems as a bug to me on Postgres 11.0:
> Yeah, somebody broke this between 10.x and 11.0. ...
> I've not looked at the code yet, but it's acting like somebody changed the
> STRICT logic from "are any of the aggregate's arguments null" to "is any
> part of the whole row (including ordering values) null". Wrong ...
git bisect fingers this:
commit 69c3936a1499b772a749ae629fc59b2d72722332
Author: Andres Freund <andres@anarazel.de>
Date: Tue Jan 9 13:25:38 2018 -0800
Expression evaluation based aggregate transition invocation.
Andres, do you have time to look at this right now?
regards, tom lane
Commits
-
Fix unused-variable warning.
- 6f4e01c7d289 11.1 landed
- 3e0b05a75673 12.0 landed
-
Prevent generating EEOP_AGG_STRICT_INPUT_CHECK operations when nargs == 0.
- 6eb31cedb316 11.1 landed
- 793beab37e8f 12.0 landed
-
Fix STRICT check for strict aggregates with NULL ORDER BY columns.
- fd59b29c8739 11.1 landed
- 4c640f4f38d5 12.0 landed
-
Expression evaluation based aggregate transition invocation.
- 69c3936a1499 11.0 cited