You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2022/04/11 07:49:18 UTC

[GitHub] [flink] slinkydeveloper commented on a diff in pull request #19409: [FLINK-24577][table-planner] Implement Cast from BINARY to RAW

slinkydeveloper commented on code in PR #19409:
URL: https://github.com/apache/flink/pull/19409#discussion_r847035102


##########
flink-table/flink-table-planner/src/main/java/org/apache/calcite/rex/RexSimplify.java:
##########
@@ -2024,7 +2029,9 @@ private RexNode simplifySearch(RexCall call, RexUnknownAs unknownAs) {
     private RexNode simplifyCast(RexCall e) {
         RexNode operand = e.getOperands().get(0);
         operand = simplify(operand, UNKNOWN);
-        if (sameTypeOrNarrowsNullability(e.getType(), operand.getType())) {
+        if (sameTypeOrNarrowsNullability(e.getType(), operand.getType())
+                || e.getType() instanceof RawRelDataType) {
+            // || e.getType().getSqlTypeName() == SqlTypeName.OTHER) {

Review Comment:
   Not sure, OTHER catches other types in our type system, right?



-- 
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: issues-unsubscribe@flink.apache.org

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