You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "KKcorps (via GitHub)" <gi...@apache.org> on 2023/03/17 10:18:57 UTC

[GitHub] [pinot] KKcorps commented on a diff in pull request #10376: [feature] [null support # 1] selection only literal in broker null support

KKcorps commented on code in PR #10376:
URL: https://github.com/apache/pinot/pull/10376#discussion_r1140044860


##########
pinot-common/src/main/java/org/apache/pinot/common/request/context/RequestContextUtils.java:
##########
@@ -230,6 +231,9 @@ private static String getStringValue(Expression thriftExpression) {
       throw new BadQueryRequestException(
           "Pinot does not support column or function on the right-hand side of the predicate");
     }
+    if (thriftExpression.getLiteral().getSetField() == Literal._Fields.NULL_VALUE) {
+      return String.valueOf(null);

Review Comment:
   We can avoid branching here and simply return "null"



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