I have an sql table with data like this:
| theDate (datetime) | theValue (int) |
----------------------------------------
| 2010-05-17 02:21:10 | 5 |
| 2009-03-12 04:11:35 | 23 |
| 2010-02-19 18:16:53 | 52 |
| 2008-07-07 22:54:11 | 30 |
这些日期存储在 datetime 列中,格式为 UTC,我该如何将它们转换为当地时间(挪威)?请记住由于冬令/夏令时的原因,UTC 偏移并非全年相同。
更新:我正在使用 Microsoft SQL Server 2005,并且需要从 SQL 中进行此操作,因为数据稍后将显示在报告中。