Open Shanmugavel-J opened 2 weeks ago
@TCeason In the sense is that it would give it wrong?
I could see the correct date for remaining timestamps but not for that specific year(didnt check all the dates but for one or two days).
In doc
Range Unit x < 31,536,000,000 Seconds 31,536,000,000 ≤ x < 31,536,000,000,000 Milliseconds x ≥ 31,536,000,000,000 Microseconds
@TCeason Okay. But the epoch time could be in negative as well correct? And if you could see i did a conversion of a date to epoch
I had attached the below image the epoch for date 10-10-1969 is shown in it. When that value is copied and executed in databend i get a different output.
Summary
Getting different value when converting the below specific epoch timestamp in milliseconds to date. The function provides correct value when trying without milliseconds for that specific year.
Query:
SELECT TO_TIMESTAMP(-7233803000);
Output:
1740-10-08 10:16:40.000
Query:
SELECT TO_TIMESTAMP(-7233803);
Output:
1969-10-09 06:36:37.000
Note: The epoch time actual date is 1969-10-09