Jackie-Jiang commented on code in PR #14233:
URL: https://github.com/apache/pinot/pull/14233#discussion_r1802473173


##########
pinot-query-planner/src/main/java/org/apache/pinot/calcite/rel/rules/PinotWindowExchangeNodeInsertRule.java:
##########
@@ -234,8 +283,13 @@ private void validateWindowFrames(Window.Group 
windowGroup) {
     }
   }
 
-  private boolean 
isRowsOnlyAggregationCallType(ImmutableList<Window.RexWinAggCall> aggCalls) {
-    return aggCalls.stream().anyMatch(aggCall -> 
aggCall.getKind().equals(SqlKind.ROW_NUMBER));
+  private boolean hasRankBasedAgg(ImmutableList<Window.RexWinAggCall> 
aggCalls) {
+    for (Window.RexWinAggCall aggCall : aggCalls) {
+      if (RANK_BASED_FUNCTION_KIND.contains(aggCall.getKind())) {
+        return true;
+      }
+    }
+    return false;

Review Comment:
   Good call. Let's add a test to ensure it doesn't get planned



-- 
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: commits-unsubscr...@pinot.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org

Reply via email to