>From the code encoding TIMESTAMP:
final long secs = vec.time[i + offset] / MILLIS_PER_SECOND;
> final int newNanos = vec.nanos[i + offset];
So for 1969-12-31 23:59:59.500, it will be:
secs = 0 (-500 / 1000)
newNanos = 500_000_000 (500ms)
Thus when the time is reading back, it will be 1970-01-01 00:00:00.500
For timestamp earlier than 1969-12-31 23:59:59, since secs will be
negative, decoder will subtracted the result by 1 second. However, for
timestamp within 1969-12-31 23:59:59 and 1970-01-01 00:00:00, it looks like
the data will be read back as a timestamp 1 second later?
Thank you !
(The encoding is https://github.com/apache/orc/blob/