Indian-boult opened a new pull request, #20332:
URL: https://github.com/apache/pinot/pull/20332

   Fixes #20328
   
   `buildAggCall` in `PinotAggregateExchangeNodeInsertRule` and in 
`AggregatePushdownRule` now maps a distinct SUM, `$SUM0` or AVG call to 
`DISTINCTSUM` or `DISTINCTAVG`, the same functions the single-stage parser uses 
for `SUM(DISTINCT x)` and `AVG(DISTINCT x)`. Before this change the distinct 
flag was dropped for these calls and the query returned `SUM(x)`.
   
   I added three queries to `Aggregates.json` that compare against H2. One has 
no GROUP BY, one groups by a column, and one sets 
`plannerRule_skipAggregateReduceFunctions=true`. On master they fail in both 
`testQueryTestCasesWithH2` and `testQueryTestCasesWithH2WithNewOptimizer`, with 
results such as `Expected Row: [531, 88.5], Actual Row: [533, 
88.83333333333333]`. With the change the full `ResourceBasedQueriesTest` 
passes, and so does the pinot-query-planner suite. Spotless, checkstyle and 
license checks pass on both modules.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to