简体   繁体   English

SQL / Navision DateTime问题

[英]SQL/Navision DateTime Issue

I don't know if anyone else has experiencing this issue before 我不知道其他人是否曾经历过这个问题

I have DateTime Data in a MsSQl table but when displaying the same data in Navison 2013, it is displaying the time wrongly. 我在MsSQl表中有DateTime数据,但是当在Navison 2013中显示相同的数据时,它会错误地显示时间。 2018-12-14 08:20:22.000 is being displayed as 14-12-18 11:20:22 AM 2018-12-14 08:20:22.000 14-12-18 11:20:22 AM正在显示为14-12-18 11:20:22 AM

Any suggestions ? 有什么建议么 ? Thanks in Advance 提前致谢

The time stored in the SQL database will be stored in UTC. 存储在SQL数据库中的时间将以UTC格式存储。 However, since you're based in Kenya (I assume from your profile), your time zone is UTC+3. 但是,由于您位于肯尼亚(我假设您的个人资料),您的时区为UTC + 3。 Navision (Dynamics NAV) automatically converts UTC time into your local time zone. Navision(动态NAV)自动将UTC时间转换为您当地的时区。

So if you're writing to the database directly without going through Navision you should use UTC time to save the time. 因此,如果您在不通过Navision的情况下直接写入数据库,则应使用UTC时间来节省时间。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM