4 ms·
My understanding is that you don't even want to store them as UTC and always store them in the timezone of the user/system that generated the data since you los
by dpcx 4y ago
My understanding is that you don't even want to store them as UTC and always store them in the timezone of the user/system that generated the data since you lose some information in the translation from local timezone to UTC - given that the timezone database changes, you may actually want to know that the record created in Fiji before 2022-10-28[1] was stored in DST so that it can be properly converted to the new Fiji time.
[1]: https://data.iana.org/time-zones/tzdb/NEWS https://data.iana.org/time-zones/tzdb/NEWS
- bouke 4y agoThis! People mistake the offset for the timezone, which is incorrect. The offset isn't very useful other than a guestimate of the originating timezone.
- cratermoon 4y agoIdeally store both, UTC and original local time, or at least the original TZ information. Time and timezone are a huge mess and one of the worst things to try deal with in programming.