Re: grouping pushdown

2023-01-04 Thread Antonin Houska
David Rowley wrote: > On Wed, 4 Jan 2023 at 23:21, Spring Zhong wrote: > > The plan is apparently inefficient, since the hash aggregate goes after the > > Cartesian product. We could expect the query's performance get much > > improved if the HashAggregate node can be pushed down to the SCAN n

Re: grouping pushdown

2023-01-04 Thread David Rowley
On Wed, 4 Jan 2023 at 23:21, Spring Zhong wrote: > The plan is apparently inefficient, since the hash aggregate goes after the > Cartesian product. We could expect the query's performance get much improved > if the HashAggregate node can be pushed down to the SCAN node. > Is someone has suggest

grouping pushdown

2023-01-04 Thread Spring Zhong
Hi hackers, I came across a problem on how to improve the performance of queries with GROUP BY clause when the grouping columns have much duplicate data. For example: create table t1(i1) as select 1 from generate_series(1,1); create table t2(i2) as select 2 from generate_series(1,1); se