The pivot year on MX is 1930 - 2029 as your output shows. This is from
the createDate function description in the MM CFML Reference (for
6.1):

"year - Integer in the range 0-9999. Integers in the range 0-29 are
converted to 2000-
2029. Integers in the range 30-99 are converted to 1930-1999. You cannot
specify dates before AD 100."

Andrew.

----- Original Message -----
From: Alisa Thomson <[EMAIL PROTECTED]>
Date: Thu, 09 Sep 2004 14:12:28 -0400
Subject: CFMX and 2-digit years
To: CF-Talk <[EMAIL PROTECTED]>

I must be missing something simple.  I know the pivot year changed in
MX, but I thought it was 20 years:

Locale is: <CFOUTPUT>#GetLocale()#</CFOUTPUT><BR>
<CFSET date1 = CreateDate(30,01,05)>
Date entered is: <CFOUTPUT>#date1#</CFOUTPUT><BR>
<CFOUTPUT>#DateFormat(date1, "mm-dd-yyyy")#</CFOUTPUT><BR>
<BR>
<CFSET date1 = CreateDate(29,01,05)>
Date entered is: <CFOUTPUT>#date1#</CFOUTPUT><BR>
<CFOUTPUT>#DateFormat(date1, "mm-dd-yyyy")#</CFOUTPUT><BR>
<BR>

Returns this:

Locale is: English (US)

Date entered is: {ts '1930-01-05 00:00:00'}
01-05-1930

Date entered is: {ts '2029-01-05 00:00:00'}
01-05-2029

BTW...I am running CFMX 6.1 on Solaris.________________________________
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

Reply via email to