Timestamps are irreversible
Posted: Thu Jun 18, 2020 9:47 pm
I think dates can be easier to handle and store as timestamps.
There is the two functions that can convert back and forth timestamps and dates, but they not works enough precisely.
The results on OS4 is:
Windows result is different:
There is the two functions that can convert back and forth timestamps and dates, but they not works enough precisely.
Code: Select all
x=DateToTimestamp("12-Jan-2020 00:00:05")
DebugPrint(x)
DebugPrint(TimestampToDate(x,True))
One hour differency could be blamed for DST, but what is that 54 seconds?1578783551
11-Jan-2020 22:59:11
Windows result is different:
That looks like exactly one hour differency, however not good to store the date.1578783605
11-Jan-2020 23:00:05