shauryachats commented on code in PR #18064:
URL: https://github.com/apache/pinot/pull/18064#discussion_r3042166493


##########
pinot-query-planner/src/main/java/org/apache/pinot/query/planner/logical/LeafStageToPinotQuery.java:
##########
@@ -98,8 +101,77 @@ private static void handleProject(Project project, 
PinotQuery pinotQuery) {
   private static void handleFilter(Filter filter, PinotQuery pinotQuery) {
     if (filter != null) {
       RexExpression rexExpression = 
RexExpressionUtils.fromRexNode(filter.getCondition());
-      
pinotQuery.setFilterExpression(CalciteRexExpressionParser.toExpression(rexExpression,
-          pinotQuery.getSelectList()));
+      Expression filterExpression = 
CalciteRexExpressionParser.toExpression(rexExpression,
+          pinotQuery.getSelectList());
+      
pinotQuery.setFilterExpression(ensureFilterIsFunctionExpression(filterExpression));

Review Comment:
   Would it be better to add `ensureFilterIsFunctionExpression` as a common 
method executed before segment pruners to ensure other invocations are not 
missed?



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to