Difference between revisions of "Understanding Service Desk Time"

From SDU
Jump to: navigation, search
m (New page: This article shows how Service Desk maintains timestamps and how to convert it to real world time.<br> --<small>Article provided by Nero Le Velu.</small> == Date/Tim...)
 
m
Line 1: Line 1:
 +
[[Category:Miscellaneous]]
 
This article shows how Service Desk maintains timestamps and how to convert it to real world time.<br>
 
This article shows how Service Desk maintains timestamps and how to convert it to real world time.<br>
 
--<small>Article provided by [[User:Nero Le Velu|Nero Le Velu]].</small>
 
--<small>Article provided by [[User:Nero Le Velu|Nero Le Velu]].</small>

Revision as of 13:20, 5 July 2008

This article shows how Service Desk maintains timestamps and how to convert it to real world time.
--Article provided by Nero Le Velu.

Date/Time

The value in date field for USD are coming from a generation that predates Windows. USD was developed on and for UNIX systems. UNIX Time it is the number of seconds elapsed since midnight of January 1, 1970.

[USD time] 0 = [Real world] 1 January 1970 at 00h00:00


The mathematic function for time is...
[Gregorian] dd/mm/yyyy h:m:s = [USD Time in second] value + 1/1/1970


For easy calculation...
USD time / 86400 = number of days from 1970


The biggest problem with conversion is the non-linear scale of Gregorian date format (there are sometimes 28, 29, 30 or 31 days a month, 365 or 366 days a year). Conversion functions existing in your query or reporting tools are typically your best resource.

Examples
SQL VB
DATE_ADD DATEADD
DATE_PART DATEDIFF
DATE_SUB DATEPART
DATEADD DATEVALUE
DATEDIFF
SUBDATE


Note: Timestamps are always recorded in GMT +0 and the system times are displayed based on the timezone of the Primary Server.


Duration

Duration is another type of time value used by Service Desk. While it is not a direct reference to time, it is the difference between two timestamps.


duration = close_date - open_date


See Also

Unix Timestamp Converter