Determine Time Zone Offset in T-SQL

后端 未结 3 929
予麋鹿
予麋鹿 2021-01-06 01:03

My database application is going to be deployed at multiple sites in different time zones.

I need a T-SQL function that will determine the UTC timestamp of midnight

3条回答
  •  执念已碎
    2021-01-06 01:30

    Check out this previous question and answer for related information:

    Effectively Converting dates between UTC and Local (ie. PST) time in SQL 2005

    (To summarize, you do need to build time zone and DST tables in Sql Server 2005. In the next version of Sql Server we get some help with time zones.)

提交回复
热议问题