dawidwys commented on a change in pull request #10595: [Flink-13197] Fix Hive
view row type mismatch when expanding in planner
URL: https://github.com/apache/flink/pull/10595#discussion_r358799550
##########
File path:
flink-table/flink-table-planner-blink/src/main/scala/org/apache/flink/table/planner/plan/utils/FlinkRelOptUtil.scala
##########
@@ -495,4 +497,48 @@ object FlinkRelOptUtil {
}
}
+ /**
+ * Creates a projection which casts a rel's output to a desired row type.
+ *
+ * <p>This method is inspired by [[RelOptUtil.createCastRel]], different
with that,
+ * we do not generate another Project if the rel is already a [[Project]].
+ *
+ * @param rel Producer of rows to be converted
+ * @param castRowType Row type after cast
+ * @return Conversion rel with castRowType
+ */
+ def createCastRel(
Review comment:
TBH, I think it would be better to have this written in Java. We should try
to add new code only in Java.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services