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


##########
flink-connectors/flink-connector-hive/src/main/java/org/apache/flink/table/planner/delegation/hive/HiveParserDMLHelper.java:
##########
@@ -154,11 +154,12 @@ public HiveParserDMLHelper(
         RelDataTypeFactory typeFactory = plannerContext.getTypeFactory();
         LinkedHashMap<String, RelDataType> targetColToCalcType = new 
LinkedHashMap<>();
         List<TypeInfo> targetHiveTypes = new ArrayList<>();
-        TableSchema tableSchema =
-                
HiveParserUtils.fromUnresolvedSchema(destTable.getUnresolvedSchema());
-        String[] fieldNames = tableSchema.getFieldNames();
+        ResolvedSchema resolvedSchema =
+                
catalogManager.resolveCatalogTable(destTable).getResolvedSchema();

Review Comment:
   After removed, this test can not pass(because we get an unresolved Schema 
when retrieve from hive), I'm not sure how you access to this `During 
decoupling Hive connector, we won't pass the ability to call method 
catalogManager.resolveCatalogTable to HiveParser.` But, currently, the 
catalogManager is widely used in the HiveParser. Do you think it's feasible to 
improve this part when doing the decoupling ? 
   
   <img width="1238" alt="image" 
src="https://user-images.githubusercontent.com/9486140/225352134-c459079a-4cb7-4f8a-85a4-2dbf5db5d669.png";>
   



-- 
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-unsubscr...@flink.apache.org

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

Reply via email to