View Single Post
Old 04-17-2023, 03:50 PM   #9
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 12,456
Karma: 8012886
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by ownedbycats View Post
Normally, I'd expect the Unix Epoch, but I suspect it was chosen against this considering the purpose of Calibre and the number of books published before 1970...
That epoch is measured in seconds since X. That scheme doesn't work with many database date types where you must store a 'real' date or empty. You could make it work by storing a large natural number (64 bit) that represents seconds (plus or minus) from some base date, but doing so would make the database hard to use. Reading a date would always require calculation.

FWIW: I was at BTL when we started worrying about whether seconds-from-1970 would be storable with the integer types we had (32 bits signed). We hadn't done anything about it before I left (1979), but we knew we had made a mistake.
chaley is offline   Reply With Quote