Monday, August 27, 2018

datetime - Daylight saving time and time zone best practices

I am hoping to make this question and the answers to it the definitive guide to dealing with daylight saving time, in particular for dealing with the actual change overs.



If you have anything to add, please do



Many systems are dependent on keeping accurate time, the problem is with changes to time due to daylight savings - moving the clock forward or backwards.



For instance, one has business rules in an order taking system that depend on the time of the order - if the clock changes, the rules might not be as clear. How should the time of the order be persisted? There are of course an endless number of scenarios - this one is simply an illustrative one.




  • How have you dealt with the daylight saving issue?


  • What assumptions are part of your solution? (looking for context here)



As important, if not more so:




  • What did you try that did not work?

  • Why did it not work?




I would be interested in programming, OS, data persistence and other pertinent aspects of the issue.



General answers are great, but I would also like to see details especially if they are only available on one platform.

No comments:

Post a Comment

plot explanation - Why did Peaches' mom hang on the tree? - Movies & TV

In the middle of the movie Ice Age: Continental Drift Peaches' mom asked Peaches to go to sleep. Then, she hung on the tree. This parti...