aiwenmo commented on code in PR #3740:
URL: https://github.com/apache/flink-cdc/pull/3740#discussion_r1855858665
##########
flink-cdc-runtime/src/test/java/org/apache/flink/cdc/runtime/parser/TransformParserTest.java:
##########
@@ -316,12 +316,13 @@ public void testGenerateProjectionColumns() {
Column.physicalColumn("name", DataTypes.STRING(),
"string"),
Column.physicalColumn("age", DataTypes.INT(), "age"),
Column.physicalColumn("address", DataTypes.STRING(),
"address"),
+ Column.physicalColumn("deposit", DataTypes.DECIMAL(10,
2), "deposit"),
Column.physicalColumn("weight", DataTypes.DOUBLE(),
"weight"),
Column.physicalColumn("height", DataTypes.DOUBLE(),
"height"));
List<ProjectionColumn> result =
TransformParser.generateProjectionColumns(
- "id, upper(name) as name, age + 1 as newage, weight /
(height * height) as bmi",
+ "id, upper(name) as name, age + 1 as newage, deposit
as deposits, weight / (height * height) as bmi",
Review Comment:
I'll handle it tonight.
##########
flink-cdc-runtime/src/main/java/org/apache/flink/cdc/runtime/parser/TransformParser.java:
##########
@@ -123,10 +123,7 @@ private static RelNode sqlToRel(
if (udf.getReturnTypeHint() != null) {
// This UDF has return type hint annotation
returnTypeInference =
- o ->
- o.getTypeFactory()
- .createSqlType(
-
convertCalciteType(udf.getReturnTypeHint()));
+ o -> convertCalciteType(o.getTypeFactory(),
udf.getReturnTypeHint());
Review Comment:
I'll handle it tonight.
--
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]