abp002 opened a new pull request, #26484: URL: https://github.com/apache/datafusion/pull/26484
## Which issue does this PR close? - Closes #26471. ## Rationale for this change `corr`, `covar_pop`, `covar_samp` and the `regr_*` functions return the same result with `DISTINCT` as without it, because their accumulators never read `is_distinct`. ## What changes are included in this PR? Their accumulators now return a not implemented error for `DISTINCT`, as `stddev` and `approx_median` already do. `corr(DISTINCT x, x)` still works, since `SingleDistinctToGroupBy` rewrites it before it reaches the accumulator. ## What is the testing strategy for this PR? New cases in `aggregate.slt`. The two `REGR_COUNT(DISTINCT ...)` results in `eliminate_join_distinct.slt` were the non-distinct counts, so they now expect the error. ## Are there any user-facing changes? These queries now fail with an error instead of returning a wrong result. -- 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]
