[Nottingham] Smearing the Leap Second?… What of time in databases?...
Michael Simms
lug at toomanysites.org
Tue Dec 6 17:47:50 UTC 2016
I strongly suspect that databases will simply count the same second
twice, meaning if your data is counted down to the second, you'll have
twice as much data as on other seconds.
Reason being, epoch time itself doesn't keep track of it, as far as I
know. Leap seconds are simply detected by the OS in the zone file, and
run a second time. The end of a minute in epoch time is sill divisable
by 60 before and after a leap second (I tested this once).
Michael Simms
On 06/12/16 14:45, Martin via Nottingham wrote:
> Folks,
>
> For anyone knowing of databases out there:
>
>
> When working with a database for storing logging/transactions through a
> leap second, one barmy question is...
>
> Will a database store leap seconds and compute with leap seconds
> accordingly?
>
>
> EG: Can you have transactions for 2015/07/01 08:59:60 (*)?
>
> And how is that extra second counted for time calculations that span
> across it?
>
> Does the leap second get counted as an extra second of time?
>
> Or are leap seconds *never considered* (ignored) for time differences?
>
> Does that mean that everyone works for free for a leap-second?!...
>
>
> Cheers,
> Martin
>
>
> *:
> http://www.japantimes.co.jp/news/2015/07/01/national/japan-record-leap-second-wednesday-morning/
>
>
>
>
> On 05/12/16 14:31, Martin via Nottingham wrote:
>> Folks,
>>
>> A bit of a ramble for what I consider to be perpetuating an unholy
>> kludge:
>>
>> Smearing the Leap Second?...
>> http://nottingham.lug.org.uk/2016/12/smearing-the-leap-second/5467
>>
>>
>> ... And then there is the world of fun and confusion about times in
>> databases... (Especially when... But then I'm sure others can comment
>> on
>> that far more eloquently than my rambling... ;-) )
>>
>> (OK, must rant that certain people on a certain part of our globe seem
>> to believe that the earth is flat and that time zones do not exist...)
>>
>> :-P
>>
>>
>> One bit missing is:
>>
>> So where is there a nice concise article summarizing how computer and
>> application time & date /should/ be robustly and reliably handled?
>>
>>
>> Go *non-leaping monotonic epoch* all the way!
>>
>> Comment and article pointers welcomed.
>>
>>
>> Cheers,
>> Martin
>
>
>
>
More information about the Nottingham
mailing list