Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

unix to cognos date conversion

Status
Not open for further replies.
Sep 20, 2002
20
GB
Hi,

whats the best method of converting a unix date e.g. seconds from 01/01/1970 to a date/datetime in cognos impromtu 6 (version 6.0.506.0)?

I currently use the following function (which I inherited from the bloke who had my job before me)...

datetime-to-date(days-from-1900-to-datetime((order_date/86400)+25568))

but this is inaccurate e.g. 1082415000 (19/04/04 22:50:00) converts to 20/04/04 but 1082414820 (19/04/04 22:47:00) converts to 19/04/04

Answers A.S.A.P. cheers :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top