morrySnow commented on code in PR #15185:
URL: https://github.com/apache/doris/pull/15185#discussion_r1052427642


##########
fe/fe-core/src/main/java/org/apache/doris/nereids/rules/expression/rewrite/rules/TypeCoercion.java:
##########
@@ -80,7 +80,8 @@ public Expression visitBinaryOperator(BinaryOperator 
binaryOperator, ExpressionR
         Expression left = rewrite(binaryOperator.left(), context);
         Expression right = rewrite(binaryOperator.right(), context);
 
-        return 
Optional.of(TypeCoercionUtils.canHandleTypeCoercion(left.getDataType(), 
right.getDataType()))
+        return 
Optional.of(TypeCoercionUtils.checkCanHandleCoercionForBinaryArithmeticChildren(binaryOperator)
+                        || 
TypeCoercionUtils.canHandleTypeCoercion(left.getDataType(), 
right.getDataType()))

Review Comment:
   it is too trick here, we need a more gracefule solution to handle all type 
coercion~



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