all groups > sql server notification services > april 2005 >
You're in the

sql server notification services

group:

SentTime field in Notificationstable



SentTime field in Notificationstable Guus van der Stap
4/10/2005 9:21:11 AM
sql server notification services: Can anyone tell me how to adjust the sentTime field in the
SentTime field in Notificationstable Guus van der Stap
4/14/2005 5:16:38 AM
To be more specific:
the actual sent time of a notification is eg. 10:30. The
SentTime attribute in the Notifications table is however
set to 08:30.

[quoted text, click to view]
Re: SentTime field in Notificationstable Shyam Pather [MSFT]
4/14/2005 11:40:53 AM
Hello,
All time values stored in the NS databases are represented in UTC. This
prevents issues that arise from daylight savings time transitions. You
cannot change how times are stored, but you can of course calculate what the
local time would be when querying.

To convert to local time, you need to figure out what the time difference
between your local time and UTC time is. You can do this as follows:

DECLARE @hourDifference INT

SELECT @hourDifference = DATEDIFF(HOUR, GETUTCDATE(), GETDATE())

SELECT DATEADD(HOUR, @hourDifference, SentTime) AS LocalSentTime

FROM NS<NotificationClassName>NotificationDistribution

Hope this helps.
-shyam
--
Learn more about SQL-NS:
http://www.amazon.com/exec/obidos/tg/detail/-/0672326647/
---------------------------------------------
This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm.
---------------------------------------------
[quoted text, click to view]

AddThis Social Bookmark Button