mihaibudiu commented on code in PR #3785:
URL: https://github.com/apache/calcite/pull/3785#discussion_r1600522936


##########
core/src/main/java/org/apache/calcite/sql/type/ReturnTypes.java:
##########
@@ -551,6 +551,13 @@ public static SqlCall stripSeparator(SqlCall call) {
       opBinding -> opBinding.getTypeFactory().leastRestrictive(
           opBinding.collectOperandTypes());
 
+  public static final SqlReturnTypeInference NVL2_RESTRICTIVE = opBinding -> {

Review Comment:
   This looks wrong. If the first operand does not have the type null then you 
need to unify the types of operands 2 and 3. In fact, I think you always need 
to unify them.



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

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

Reply via email to