pvary commented on code in PR #14245:
URL: https://github.com/apache/iceberg/pull/14245#discussion_r2439476221


##########
flink/v2.1/flink/src/main/java/org/apache/iceberg/flink/data/FlinkParquetReaders.java:
##########
@@ -404,8 +404,10 @@ private static class NanosToTimestampReader
     @Override
     public TimestampData read(TimestampData ignored) {
       long value = readLong();
+      long mills = Math.floorDiv(value, 1_000_000_000L);
+      long nanos = Math.floorMod(value, 1_000_000_000L);
       return TimestampData.fromEpochMillis(
-          Math.floorDiv(value, 1_000_000L), Math.floorMod(value, 1_000_000));
+          mills + Math.floorDiv(nanos, 1_000_000L), (int) Math.floorMod(nanos, 
1_000_000L));

Review Comment:
   I don't understand this change.
   Why are we precalculating seconds? And then again converting to millis?



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to