Why don't you use CreateODBCDate() / CreateODBCDateTime()?
Along with <CFQUERYPARAM>

That never gives problems.



----- Original Message ----- 
From: "Jason Smith" <[EMAIL PROTECTED]>
To: "CF-Talk" <[email protected]>
Sent: Tuesday, December 21, 2004 8:17 PM
Subject: Re: Date Issues


> That is a very helpful piece of code right there
>
> MYSQL is outputting the date - 2012-07-20 04:00:00.0
> and of course the original writer of the cf app has MM/DD/YYYY as the
> output in his code.
>
> Now I'm assuming I can just change the output format on all 48 pages that
> use it and I should be good to go, anything else I might need to watch out
for?
>
>
> At 12:13 PM 12/21/2004, you wrote:
> >try:
> ><cfdump var="#form#">
> ><cfabort>
> >above the code you've written.
> >Paste the output exactly.
> >
> >
> >
> >On Tue, 21 Dec 2004 14:04:40 -0500, Burns, John D
> ><[EMAIL PROTECTED]> wrote:
> > > Are you sure that's not the date that it's feeding in?  Are you
positive
> > > your date format is written correctly.  I looks like 2012 is coming up
> > > for December which leads me to believe that it's reading in MM/DD/YY
and
> > > it thinks it's coming in as YY/MM/DD.  Are you sure you're using the
> > > 4-digit year and that you've tried it as YYYY/MM/DD?  That was what
had
> > > solved it for me.
> > >
> > >
> > > John Burns
> > > Certified Advanced ColdFusion MX Developer
> > > AI-ES Aeronautics, Web Developer
> > >
> > > -----Original Message-----
> > > From: Jason Smith [mailto:[EMAIL PROTECTED]
> > > Sent: Tuesday, December 21, 2004 1:58 PM
> > > To: CF-Talk
> > > Subject: RE: Date Issues
> > >
> > > I tried that in the beginning thinking it might have something to do
> > > with it. But all that does is reverse the date 2012/07/20 what I
really
> > > can't figure out is where it could possibly be pulling that date from.
> > >
> > > At 11:54 AM 12/21/2004, you wrote:
> > > >I know when I was using MySQL, it used the dateformat of YYYY/MM/DD
> > > >instead of MM/DD/YYYY.  You may need to fix your dateFormat to
display
> > > >that correctly.
> > > >
> > > >
> > > >John Burns
> > > >Certified Advanced ColdFusion MX Developer AI-ES Aeronautics, Web
> > > >Developer
> > > >
> > > >-----Original Message-----
> > > >From: Jason Smith [mailto:[EMAIL PROTECTED]
> > > >Sent: Tuesday, December 21, 2004 1:48 PM
> > > >To: CF-Talk
> > > >Subject: Date Issues
> > > >
> > > >Can anyone narrow down what the problem might be:
> > > >
> > > >The site I'm working on was built for access, I ported it to mysql
> > > >after making all the needed changes for date stamps and anything else
> > > >incompatible I have a new issue that seems to be random. When
updating
> > > >an Item via the administration application I have:
> > > >
> > > >
> > > >*Item Date Received:
> > > >
> > > ><cfif isDate('#FORM.itemDateRecieved#')>
> > > >          <cfoutput><cfset DR = #DateFormat(FORM.itemDateRecieved,
> > > >'MM/DD/YYYY')#></cfoutput>
> > > >
> > > ><cfelse>
> > > >          <cfoutput><cfset DR = #FORM.itemDateRecieved#></cfoutput>
> > > ></cfif>
> > > ><!---ITEM DATE RECIEVED--->
> > > ><tr>
> > > >          <td class="formTitle"><span class="votitle">*Item Date
> > > >Received:</span></td>
> > > >          <td><cfif enabledYN eq "disabled"><span
> > > >style="color:gray;"><cfoutput>#DR#</cfoutput></span><cfelse><cfinput
> > > >type="text" name="itemDateRecieved" class="formBox"
> > > >value="#DR#"></cfif></td> </tr> <tr> <td>&nbsp;</td> <td><span
> > > >class="small">MM/DD/YYYY</span></td>
> > > ></tr>
> > > >
> > > >Now when you update an item everything runs fine and seems to update
> > > >but on certain items dates are still fouled up. One in particular I'm
> > > >working on is always showing date 07/20/2012 and refuses to take
> > > >anything else. Now could anyone tell me is this a cf problem or
> > > >possibly a problem with the data field?
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Special thanks to the CF Community Suite Silver Sponsor - RUWebby
http://www.ruwebby.com

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:188467
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to