Github user clockfly commented on the issue:
https://github.com/apache/spark/pull/14546
I think the root cause is that the Aggregate operator is treated as
resolved if even it has group by ordinals.
For example:
```
'Filter ('a > 0)
+- Aggregate [2], [count(1) AS count(1)#83L, a#81]
+- SubqueryAlias tmp
+- Project [1 AS a#81]
+- OneRowRelation$
```
Aggregate is treated as resolved even if it has a group by ordinal "2".
Then, it tries to resolve the `Filter` by putting the `Filter` as a
aggregation expression:
```
!'Aggregate [2], [('a > 0) AS havingCondition#84]
+- SubqueryAlias tmp
+- Project [1 AS a#81]
+- OneRowRelation$
```
Actually this plan is already wrong. As we are asking for ordinal "2", but
actually there is only one
aggregation expression `[('a > 0) AS havingCondition#84] `
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]