xuefuz commented on a change in pull request #9502: [FLINK-13814][hive] 
HiveTableSink should strip quotes from partition …
URL: https://github.com/apache/flink/pull/9502#discussion_r316821021
 
 

 ##########
 File path: 
flink-connectors/flink-connector-hive/src/main/java/org/apache/flink/connectors/hive/HiveTableSink.java
 ##########
 @@ -170,7 +171,7 @@ public void setStaticPartition(Map<String, String> 
partitionSpec) {
                staticPartitionSpec = new LinkedHashMap<>();
                for (String partitionCol : getPartitionFieldNames()) {
                        if (partitionSpec.containsKey(partitionCol)) {
-                               staticPartitionSpec.put(partitionCol, 
partitionSpec.get(partitionCol));
+                               staticPartitionSpec.put(partitionCol, 
PlanUtils.stripQuotes(partitionSpec.get(partitionCol)));
 
 Review comment:
   Just curious, partitionSpec is a map of strings, and the value should 
probably have been unquoted before getting here. I'm wondering if the fix 
should be at a lower level than here. Otherwise, similar fix will be needed 
wherever such partition spec is used.

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

Reply via email to