Re: How to convert a number into date?

2006-06-05 Thread David Strong
Michael wrote: Now, you have asked the right question. ;-) See if this helps: http://www.cflib.org/udf.cfm?ID=1339 Tried to test your function with Johnny's number but it kicks an invalid date parsing error. ~| Message:

Re: How to convert a number into date?

2006-06-04 Thread Johnny Le
Someone must have epxerienced this problem before. The number is the lastlogon date produced by the Active Directory (Windows 2000) when I used LDAP to query it. Let me know if you know how to parse it now. Johnny The number can be a misinterpreted representation of the Unix Epoch time.

Re: How to convert a number into date?

2006-06-04 Thread David Strong
Remember the EPOCH times for Unix and Windows are different. Try this, read the comments I have included for you: !--- Problem: LDAP date is returned as NANOSECONDS and if you try to write a function to parse it CFMX returns an error saying the number is too big to fit in integer

RE: How to convert a number into date?

2006-06-04 Thread Dawson, Michael
Now, you have asked the right question. ;-) See if this helps: http://www.cflib.org/udf.cfm?ID=1339 M!ke -Original Message- From: Johnny Le [mailto:[EMAIL PROTECTED] Sent: Sunday, June 04, 2006 12:35 PM To: CF-Talk Subject: Re: How to convert a number into date? Someone must have

Re: How to convert a number into date?

2006-06-04 Thread Johnny Le
Wow, David, that works. Thank you. Wonder why they chose 1/1/1601 as the starting point. Johnny Remember the EPOCH times for Unix and Windows are different. Try this, read the comments I have included for you: !--- Problem: LDAP date is returned as NANOSECONDS and if you try

Re: How to convert a number into date?

2006-06-04 Thread Paul Hastings
David Strong wrote: Remember the EPOCH times for Unix and Windows are different. just an fyi: there are more than 1 windows epoch depending on what you're doing. besides the windows file time (ticks or 100 nanoseconds since 1-jan-1601) there's now also dotnet datetime (ticks since

Re: How to convert a number into date?

2006-06-04 Thread Paul Hastings
Johnny Le wrote: Wonder why they chose 1/1/1601 as the starting point. because it's the beginning of the last 400-year cycle by which leap-years are calculated in the Gregorian calendar, which was followed by a new 400-year cycle beginning with 2001.

Re: How to convert a number into date?

2006-06-03 Thread David Strong
The number can be a misinterpreted representation of the Unix Epoch time. (The number of seconds passed since January 1 1970 00:00:00). But I believe your number is way too big. Please we need more info on the origins of your number.

How to convert a number into date?

2006-06-02 Thread Johnny Le
Hi, How do I turn this number 127937470871482500 into date? When I tried isNumericDate(), it returns yes, but I don't know how to display it in a readable format. Thanks. Johnny ~| Message:

RE: How to convert a number into date?

2006-06-02 Thread Dawson, Michael
Did you try dateFormat()? -Original Message- From: Johnny Le [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 7:00 PM To: CF-Talk Subject: How to convert a number into date? Hi, How do I turn this number 127937470871482500 into date? When I tried isNumericDate(), it returns yes,

Re: How to convert a number into date?

2006-06-02 Thread Johnny Le
How? I tried dateFormat(number, mm/dd/yy) and it returns 12/02/292269055. I think it is because it is supposed to return both date and time. Let me know if you want to format it to display both date and time. Johnny Did you try dateFormat()? -Original Message- From: Johnny Le

RE: How to convert a number into date?

2006-06-02 Thread Eric Roberts
to convert a number into date? How? I tried dateFormat(number, mm/dd/yy) and it returns 12/02/292269055. I think it is because it is supposed to return both date and time. Let me know if you want to format it to display both date and time. Johnny Did you try dateFormat()? -Original