Re: Wrong results with grouping sets
Richard Guo <guofenglinux@gmail.com>
From: Richard Guo <guofenglinux@gmail.com>
To: Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>, PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2024-07-10T01:22:54Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Remove the RTE_GROUP RTE if we drop the groupClause
- ffe12d1d22e7 18.0 landed
-
Mark expressions nullable by grouping sets
- f5050f795aea 18.0 landed
-
Introduce an RTE for the grouping step
- 247dea89f761 18.0 landed
Attachments
- v10-0001-Introduce-an-RTE-for-the-grouping-step.patch (application/octet-stream) patch v10-0001
- v10-0002-Mark-expressions-nullable-by-grouping-sets.patch (application/octet-stream) patch v10-0002
On Sat, Jul 6, 2024 at 9:26 AM Richard Guo <guofenglinux@gmail.com> wrote: > On Thu, Jul 4, 2024 at 6:02 PM Ashutosh Bapat > <ashutosh.bapat.oss@gmail.com> wrote: > > I don't have any specific thoughts on backpatching, but I have started > > reviewing the patches. > Thanks for reviewing this patchset! Here is an updated version of this patchset. I've added some comments according to the review feedback, and also tweaked the commit messages a bit more. Additionally, I've made a change to only add the new RTE_GROUP RTE when there are acceptable GROUP BY expressions. This allows us to skip all the trouble of doing this for queries without GROUP BY clauses. Thanks Richard