public inbox for [email protected]
help / color / mirror / Atom feedFrom: Kohei KaiGai <[email protected]>
To: Pg Hackers <[email protected]>
Subject: Using non-grouping-keys at HAVING clause
Date: Fri, 8 Sep 2023 16:42:57 +0900
Message-ID: <CAOP8fzbzmDRZj4zHb_nCGCW6YM6RhemHgwnwAK4KFPh8LXpR7g@mail.gmail.com> (raw)
Hello,
I got a trouble report here:
https://github.com/heterodb/pg-strom/issues/636
It says that PG-Strom raised an error when the HAVING clause used
non-grouping-keys,
even though the vanilla PostgreSQL successfully processed the query.
SELECT MAX(c0) FROM t0 GROUP BY t0.c1 HAVING t0.c0<MIN(t0.c0);
However, I'm not certain what is the right behavior here.
The "c0" column does not appear in the GROUP BY clause, thus we cannot
know its individual
values after the group-by stage, right?
So, what does the "HAVING t0.c0<MIN(t0.c0)" evaluate here?
Best regards,
--
HeteroDB, Inc / The PG-Strom Project
KaiGai Kohei <[email protected]>
view thread (2+ messages)
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected]
Subject: Re: Using non-grouping-keys at HAVING clause
In-Reply-To: <CAOP8fzbzmDRZj4zHb_nCGCW6YM6RhemHgwnwAK4KFPh8LXpR7g@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox