Friday, March 9, 2012

HelpNeed to convert number to DateTime

Hi! I'm not very technical, so please excuse me if I don't make sense...

I'm pulling Date/Time data from an Oracle database using Crystal 10, however, instead of getting a number in DateTime format, I'm getting a really long number that does not convert when using the DateTime function (I get an error stating that the year is greater than 9999.)

The number is 1123876247 (the actual date should be 8/12/2005 12:50). Sound familiar? Does anyone have any ideas on how to convert this number?

Any help is greatly appreciated!! (I'm about to pull my hair out!)How is 1123876247 related to 8/12/2005 12:50?|||1123876247 is 8/12/2005 represented in seconds since a certain date. Since my last post, I have since found that date to be 01/01/1970. So, the formula is:

DateAdd("s", (11238876247), #1970/01/01#)

This works to convert the seconds into Date/Time format.

No comments:

Post a Comment