gabotechs commented on code in PR #14413: URL: https://github.com/apache/datafusion/pull/14413#discussion_r2011760705
########## datafusion/functions-aggregate/src/array_agg.rs: ########## @@ -131,7 +133,32 @@ impl AggregateUDFImpl for ArrayAgg { let data_type = acc_args.exprs[0].data_type(acc_args.schema)?; if acc_args.is_distinct { - return Ok(Box::new(DistinctArrayAggAccumulator::try_new(&data_type)?)); + // Limitation similar to Postgres. The aggregation function can only mix Review Comment: I updated the `user_doc` with a brief explanation about how DISTINCT + ORDER BY work with the ARRAY_AGG function, along with an example. Do you think the "Postgres style" limitation is something that could be applied to all aggregation functions? For the ARRAY_AGG specifically it seems like it delivers a good results/complexity ratio, but I imagine that applied this limitation globally would require at least some internal consensus from PMC people. -- 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: github-unsubscr...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org