aldol
April 4, 2014, 8:03pm
1
Hello,
We are using MS Dynamics NAV 2009 R2 Version NAVIGATOR 5.00.02.01, US Dynamics NAV 5.0 SP1 (6.00.32012)
The NAV DateTime 14/03/21 03:40:16.213 PM is showing as 2014-03-21 22:40:16.213 in SQL 2008 SP1
Please, help with how I could conver it properly to show the correct time from NAV in SQL that I would use as the date and time for SSRS reporting.
Thanks,
Alex
aldol
April 4, 2014, 8:51pm
2
It seems I found a solution calculating a difference between the current and UTC time as below. Please, advise if it could be Ok or there is another proper way of doing it.
SELECT
DATEADD(millisecond,-DATEDIFF(millisecond, GETDATE(), GETUTCDATE()), ‘2014-03-21 22:40:16.213’
);
–2014-03-21 15:40:16.213
–14/03/21 03:40:16.213 PM
Thanks