Skip to content

[CALCITE-7362] Add rule to transform WHERE clauses into filtered aggregates#4808

Open
zabetak wants to merge 1 commit intoapache:mainfrom
zabetak:CALCITE-7362
Open

[CALCITE-7362] Add rule to transform WHERE clauses into filtered aggregates#4808
zabetak wants to merge 1 commit intoapache:mainfrom
zabetak:CALCITE-7362

Conversation

@zabetak
Copy link
Member

@zabetak zabetak commented Feb 26, 2026

No description provided.

Copy link
Member

@xiedeyantu xiedeyantu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have no further valuable comments on mhai, only a few minor suggestions.

*/
class AggregateFilterToFilteredAggregateRuleTest {

private static RelOptFixture fixture() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we inherit a base class to avoid writing fixture() and sql(String) in every test class? Although we are currently discussing how to use quidem to implement a better testing framework. Of course, this could also be addressed in a new PR; I'm just mentioning the idea.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are pros and cons for using inheritance and in this case I opted against. Item 18 and 19 in Effective Java by Joshua Bloch has some pertinent information around the use of inheritance.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we should expose each developer to too much extra work, as it increases the cost of understanding. But perhaps that's not so important, because we're already planning a new testing system.

Copy link
Member

@xiedeyantu xiedeyantu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@sonarqubecloud
Copy link

sonarqubecloud bot commented Mar 2, 2026

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants