On Sat, 18 Oct 2025 at 11:24, David Rowley <dgrowleyml@gmail.com> wrote:
>
> On Sat, 18 Oct 2025 at 11:18, Yuri Zamyatin <yuri@yrz.am> wrote:
> > Nice, should I still try to reproduce the bug
> > with assertions and the patch you provided?
>
> I think I've got it. I can get the Asserts in the patch to fail with:
>
> drop table if exists ab;
> create table ab (a int, b int);
> insert into ab select x%2,x%99 from generate_series(1,1001)x;
>
> select a,b,count(*) from ab group by grouping sets(b,a,(a,b),a,b);
Here's a patch which I think should fix the issue. It'd be great if
you could patch with that and ensure that there's no more crashing.
Many thanks for assisting with this.
David