devinjdangelo commented on code in PR #9606:
URL: https://github.com/apache/arrow-datafusion/pull/9606#discussion_r1525517935
##########
datafusion/sql/src/unparser/plan.rs:
##########
@@ -176,7 +250,9 @@ impl Unparser<'_> {
)
}
LogicalPlan::Aggregate(_agg) => {
Review Comment:
Thank you @seddonm1! You are right. I cooked up a test case that looks
similar to the plan you show.
```
Sort: COUNT(*) ASC NULLS LAST
Projection: person.id, COUNT(*), person.first_name
Filter: COUNT(*) > Int64(5)
Aggregate: groupBy=[[person.first_name, person.id]], aggr=[[COUNT(*)]]
TableScan: person
```
```sql
select id, count(*), first_name
from person
group by first_name, id
having count(*)>5
order by count(*)
```
This case will of course fail in the PR. I think that is OK, as we can work
on support for more complex aggregations and additional edge cases we find in
future PRs.
--
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]