JackieTien97 commented on code in PR #17937:
URL: https://github.com/apache/iotdb/pull/17937#discussion_r3412046717
##########
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/relational/analyzer/StatementAnalyzer.java:
##########
@@ -2869,6 +2880,9 @@ private Analysis.GroupingSetAnalysis analyzeGroupBy(
"%s is not comparable, and therefore cannot be used in
GROUP BY", type));
}
}
+ if (groupBy.isAll()) {
+ validateAllGroupByWindowFunctions(allGroupByExpressions, scope,
outputExpressions);
+ }
Review Comment:
Add a IT for
```
SELECT device_id, avg(s1)
FROM table1
GROUP BY ALL
ORDER BY rank() OVER (ORDER BY s1)
```
##########
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/relational/analyzer/StatementAnalyzer.java:
##########
@@ -2869,6 +2880,9 @@ private Analysis.GroupingSetAnalysis analyzeGroupBy(
"%s is not comparable, and therefore cannot be used in
GROUP BY", type));
}
}
+ if (groupBy.isAll()) {
+ validateAllGroupByWindowFunctions(allGroupByExpressions, scope,
outputExpressions);
+ }
Review Comment:
You shouldn't do this check here, you need to change the previous
AggregationAnalyzer#visitFunctionCall
--
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]