Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Let's say I have a world wide website ( I mean it has uses from all around the world).

I have 1 server which is in germany ( at some city). it will never be moved from germany - ever.

My question is :

When users saves data , I need to save the action date :

Should I save ( and I think I do) it as UTC ?

Or since - the server is in one location - it is ok to save all the dates as GetDATE() so the point of relativity is the same point.

Am I wrong ? If I do , can you please supply a simple scenario where it's gonna fail ?

share|improve this question
up vote 5 down vote accepted

Always store data in the database in UTC and then use the appropriate timezone to convert it during display, in the application. Is the only sensible approach when it comes to consider data mobility (geo-replication), user location and , most importantly, daylight savings. If you store local time there will be times when you cannot distinguish between column values and you cannot order them properly due to daylight savings. Think that, in Germany, Oct. 27th 2:05 am will happen twice this year... And that is an easy case compared to, say, Morocco.

share|improve this answer
Thank you Remus.So the only problem is with daylight saving where a time could happend twice ( ? becuase of changing the clock to one hour prior ? ) – Royi Namir May 7 '13 at 10:47
Nope, look at Samoa they completely moved their timezone forward. – billinkc May 7 '13 at 15:16
@billinkc I read it. but can you explain the actual problem here ? does the actual problem is that a time can occur twice ? please elaborate. – Royi Namir May 8 '13 at 6:37

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.