Dear Barry, Tried using <cfqueryparam value="#ParseDateTime(dateSchedule)#" cfsqltype="cf_sql_timestamp"> where dateSchedule is a constructed string "01-11-2004 10:21:10" which is in dd-mm-yyyy format.
What you said is right, it could be the way I am constructing the date/timestamp and hence cfqueryparam may not be at fault.. I'll just review the code. Cheers, Sameer 1) >> Although it works fine when used with a Now() function. which is already a dateTime object, that's why it works. 2) are you sure "cf_sql_timestamp" is the correct type? I thought it'd be "cf_sql_date" (or do you need ot pass to the time as well? SQLServer needs to...if so then try converting the value to a full dateTime value) 3) " Have you tried setting the date using the yyyy/mm/dd format?" the ISO date format is actually yyyy-mm-dd (yeah I got it wrong for a while too). try this - it may help <cfqueryparam value="#dateFormat(dateSchedule, "yyyy-mm-dd")#" cfsqltype="cf_sql_timestamp"> 4) just a thought, trace the value wherever possible. are you *sure* cfqueryparam is at fault? it may be earlier code... cheers barry.b -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Gorst, Nick Sent: Monday, 1 November 2004 2:22 PM To: CFAussie Mailing List Subject: [cfaussie] Re: Oracle Date Problem Have you tried setting the date using the yyyy/mm/dd format? The other possibility is to specify a three character text month as in yyyy/mmm/dd -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Sameer Kekade Sent: Monday, 1 November 2004 2:14 PM To: CFAussie Mailing List Subject: [cfaussie] Re: Oracle Date Problem Yeh cus ramdomly the code returns 11/01/2004 at one instance and 01/11/2004 on the other. And cfqueryparam isnt working either <cfqueryparam value="#dateSchedule#" cfsqltype="cf_sql_timestamp"> Although it works fine when used with a Now() function. Warm Regards, Sameer S. Kekade. QUATRO FOUR RETAIL "The right connections for your business" Tel. direct +61 2 9370 2775 Tel. direct +61 2 9370 1062 Fax direct +61 2 9370 1200 Mobile 0409 156 038, 0411 566 650 [EMAIL PROTECTED] www.quatro.com.au -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Mark Mandel Sent: Monday, 1 November 2004 11:33 AM To: CFAussie Mailing List Subject: [cfaussie] Re: Oracle Date Problem Yes - Use CFQUERYPARAM, and a real Date object, and you should be fine. Works fine with Oracle. It seems somewhere there is some confusion b/w the American date, and the Oz date format. Mark On Mon, 01 Nov 2004 11:12:09 +1100, Sameer Kekade <[EMAIL PROTECTED]> wrote: > Hey all, > > I am using an update statement in oracle to update a date field, and > for some reason the date/timestamp stored is "11/01/2004 11:01:27" > instead of "01/11/2004 11:01:27" > > <cfset datetime = DateFormat(dateSchedule, "dd-mm-yyyy") & " " & > TimeFormat(delay_time, "HH:mm:ss")> > > <CFQUERY DATASOURCE="#application.config.DSN#" DBTYPE="ODBC"> > UPDATE REMINDER > SET REMINDER_TIME = to_date('#datetime#','dd-mm-yyyy > HH24:mi:ss') > WHERE STATUS = 'SCHEDULED' > </CFQUERY> > > Does anyone know the best way to tackle this? > > Thanks in advance. > > Warm Regards, > Sameer S. Kekade. > QUATRO FOUR RETAIL > "The right connections for your business" > Tel. direct +61 2 9370 2775 > Tel. direct +61 2 9370 1062 > Fax direct +61 2 9370 1200 > Mobile 0409 156 038, 0411 566 650 > [EMAIL PROTECTED] > www.quatro.com.au > > --- > You are currently subscribed to cfaussie as: [EMAIL PROTECTED] To > unsubscribe send a blank email to > [EMAIL PROTECTED] > Aussie Macromedia Developers: http://lists.daemon.com.au/ > -- E: [EMAIL PROTECTED] W: www.compoundtheory.com ICQ: 3094740 --- You are currently subscribed to cfaussie as: [EMAIL PROTECTED] To unsubscribe send a blank email to [EMAIL PROTECTED] Aussie Macromedia Developers: http://lists.daemon.com.au/ --- You are currently subscribed to cfaussie as: [EMAIL PROTECTED] To unsubscribe send a blank email to [EMAIL PROTECTED] Aussie Macromedia Developers: http://lists.daemon.com.au/ Please Note: This communication has been sent on behalf of The Royal Automobile Club of Queensland Limited (RACQ). The information contained in this communication may be privileged and confidential. If you are not the intended recipient, any use, disclosure or copying of this communication is expressly prohibited. If you have received this communication in error, please delete it immediately. RACQ and its associated entities do not warrant or represent that this communication (including any enclosed files) is free from electronic viruses, faults or defects. If this is a commercial electronic message within the meaning of the Spam Act(2003), you may indicate that you do not wish to receive any further commercial electronic messages from RACQ by sending an e-mail to [EMAIL PROTECTED] with your details or by contacting RACQ on 131905 --- You are currently subscribed to cfaussie as: [EMAIL PROTECTED] To unsubscribe send a blank email to [EMAIL PROTECTED] Aussie Macromedia Developers: http://lists.daemon.com.au/ --- You are currently subscribed to cfaussie as: [EMAIL PROTECTED] To unsubscribe send a blank email to [EMAIL PROTECTED] Aussie Macromedia Developers: http://lists.daemon.com.au/ --- You are currently subscribed to cfaussie as: [EMAIL PROTECTED] To unsubscribe send a blank email to [EMAIL PROTECTED] Aussie Macromedia Developers: http://lists.daemon.com.au/
