abhishekagarwal87 commented on a change in pull request #11923:
URL: https://github.com/apache/druid/pull/11923#discussion_r766532567



##########
File path: 
sql/src/main/java/org/apache/druid/sql/calcite/rule/DruidLogicalValuesRule.java
##########
@@ -93,24 +94,28 @@ public void onMatch(RelOptRuleCall call)
    *
    * @throws IllegalArgumentException for unsupported types
    */
+  @Nullable
   @VisibleForTesting
   static Object getValueFromLiteral(RexLiteral literal, PlannerContext 
plannerContext)
   {
+    if (RexLiteral.value(literal) == null) {

Review comment:
       http://sqlfiddle.com/#!9/7fff3f/35
   
   looks like it is another place to use `useStrictBoolean` flag? :) But my 
larger point was around the internal calcite quirks that we might not be aware 
of. I am concerned that we will accidentally change the behaviour of existing 
queries as happened here. I will suggest keeping the scope of this PR to just 
fixing the bug. 




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