Aitozi commented on code in PR #20855:
URL: https://github.com/apache/flink/pull/20855#discussion_r1045211502


##########
flink-connectors/flink-connector-hive/src/main/java/org/apache/flink/table/planner/delegation/hive/HiveParserUtils.java:
##########
@@ -1689,4 +1694,61 @@ public static boolean 
isFromTimeStampToDecimal(RelDataType srcType, RelDataType
         return srcType.getSqlTypeName().equals(SqlTypeName.TIMESTAMP)
                 && targetType.getSqlTypeName().equals(SqlTypeName.DECIMAL);
     }
+
+    /**
+     * Helps to migrate the new {@link Schema} to old API methods. HiveCatalog 
use deprecated {@link
+     * TableSchema}, other catalogs may use the new {@link Schema}. Currently, 
we use it to unify to
+     * {@link TableSchema}. It should be dropped after dropping {@link 
TableSchema}.
+     */
+    public static TableSchema fromUnresolvedSchema(Schema schema) {
+        final TableSchema.Builder builder = TableSchema.builder();
+
+        final DataType unresolvedType = DataTypes.TIMESTAMP(3);

Review Comment:
   Hi @luoyuxia , I have a question here, why here unresolvedType is hard coded 
`TIMESTAMP(3)` ? 



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

Reply via email to