Skip to content

Commit a498f83

Browse files
author
aokolnychyi
committed
[SPARK-17914][SQL] Added a comment about truncation
1 parent 4d057c9 commit a498f83

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/util/DateTimeUtils.scala

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -399,6 +399,7 @@ object DateTimeUtils {
399399
digitsMilli += 1
400400
}
401401

402+
// We are truncating the nanosecond part, which results in loss of precision
402403
while (digitsMilli > 6) {
403404
segments(6) /= 10
404405
digitsMilli -= 1

0 commit comments

Comments
 (0)