leonardBang commented on a change in pull request #15356:
URL: https://github.com/apache/flink/pull/15356#discussion_r602090959



##########
File path: 
flink-formats/flink-csv/src/main/java/org/apache/flink/formats/csv/CsvRowSerializationSchema.java
##########
@@ -319,7 +323,12 @@ private static RuntimeConverter 
createRuntimeConverter(TypeInformation<?> info)
             return (csvMapper, container, obj) -> 
container.textNode(obj.toString());
         } else if (info.equals(Types.LOCAL_DATE_TIME)) {
             return (csvMapper, container, obj) ->
-                    
container.textNode(DATE_TIME_FORMATTER.format((LocalDateTime) obj));

Review comment:
       I checked the change is safe, although `DATE_TIME_FORMATTER `  supports 
`2020-01-01 12:18` and `2020-01-01 12:18:00` format and `SQL_TIMESTAMP_FORMAT ` 
only supports `2020-01-01 12:18:00`, but current deserializers use 
`Timestamp.valueOf(tiemstampString)`  which only supports `2020-01-01 
12:18:00`, and all serializers use `LocalDateTime` object which won't produce 
timestamp string like `2020-01-01 12:18`.  




-- 
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:
us...@infra.apache.org


Reply via email to