You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2022/12/09 19:25:32 UTC

[GitHub] [pinot] walterddr commented on a diff in pull request #9909: [multistage] fix function usage of casting

walterddr commented on code in PR #9909:
URL: https://github.com/apache/pinot/pull/9909#discussion_r1044769527


##########
pinot-query-runtime/src/main/java/org/apache/pinot/query/runtime/operator/FilterOperator.java:
##########
@@ -92,7 +95,7 @@ private TransferableBlock transform(TransferableBlock block)
     List<Object[]> resultRows = new ArrayList<>();
     List<Object[]> container = block.getContainer();
     for (Object[] row : container) {
-      if (_filterOperand.apply(row)) {
+      if ((Boolean) FunctionInvokeUtils.convert(_filterOperand.apply(row), DataSchema.ColumnDataType.BOOLEAN)) {

Review Comment:
   TransformOperand is function, literal or reference. it is not necessarily function. 
   the only difference is that TransformOperator returns Object and FilterOperator casts the Operand result into Boolean for a filter



-- 
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-unsubscribe@pinot.apache.org

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


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