Duncan/anyone - any ideas why this is happening though out of interest -
shouldn't be a problem trying to enter an empty string should there?
_______________________________________________________
* Regards,
Richard Lovelock,
Senior Application Analyst.
Westminster City Council - Web Support
Cap Gemini Ernst & Young
Southbank
95 Wandsworth Road
London
SW8 2HG
( 0870 906 7482
_______________________________________________________
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
Sent: 24 February 2004 10:44
To: [EMAIL PROTECTED]
Subject: Re: [ cf-dev ] trying to update date field in Access
<cfquery datasource="#dsn#">
UPDATE VintageReport
SET Yields = #Form.Yields#,
Rainfall = #Form.Rainfall#,
Sunshine = #Form.Sunshine#,
<cfif Len(Form.Flowering)>
Flowering = '#Form.Flowering#',
</cfif>
<cfif Len(Form.Veraison)>
Veraison = '#Form.Veraison#',
</cfif>
<cfif Len(Form.Harvest)>
Harvest = '#Form.Harvest#',
</cfif>
VintageReportOther = '#Form.VintageReportOther#'
WHERE Wine_ID = #Cookie.wineid#
</cfquery>
Duncan Cumming
IT Manager
http://www.alienationdesign.co.uk
mailto:[EMAIL PROTECTED]
Tel: 0141 575 9700
Fax: 0141 575 9600
Creative solutions in a technical world
----------------------------------------------------------------------
Get your domain names online from:
http://www.alienationdomains.co.uk
Reseller options available!
----------------------------------------------------------------------
----------------------------------------------------------------------
Damien
Gallagher To: [EMAIL PROTECTED]
<[EMAIL PROTECTED] cc:
oir.net> Subject: [ cf-dev ] trying to
update date field in Access
24/02/2004
10:38
Please
respond to
dev
Hi all,
I'm having a problem with updating a simple date field in MS Access.
The problem lies where I try to pass an empty string and it comes up with
an
ODBC error even though the field is NOT required.
The code is:
<cfquery datasource="#dsn#">
UPDATE VintageReport
SET Yields = #Form.Yields#,
Rainfall = #Form.Rainfall#,
Sunshine = #Form.Sunshine#,
Flowering = '#Form.Flowering#',
Veraison = '#Form.Veraison#',
Harvest = '#Form.Harvest#',
VintageReportOther = '#Form.VintageReportOther#'
WHERE Wine_ID = #Cookie.wineid#
</cfquery>
The error output contains:
Error Code: Error Executing Database Query. [Macromedia][SequeLink JDBC
Driver]
[ODBC Socket][Microsoft][ODBC Microsoft Access Driver] Syntax error in
UPDATE
statement
SQL UPDATE VintageReport SET Yields = 60, Rainfall = 2 , Sunshine = 100 ,
Flowering = '', Veraison = '', Harvest = '', VintageReportOther = 'none'
WHERE
Wine_ID = 244
DATASOURCE IWIN02 VENDORERRORCODE -3503 SQLSTATE 42000
- where Flowering, Veraison, and Harvest are the date fields
Any ideas?
Thanks,
Damien
----------------------------------------------
This mail sent through http://www.ukonline.net
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]
=======================================================
This message contains information that may be privileged or confidential and is the
property of the Cap Gemini Ernst & Young Group. It is intended only for the person to
whom it is addressed. If you are not the intended recipient, you are not authorised to
read, print, retain, copy, disseminate, distribute, or use this message or any part
thereof. If you receive this message in error, please notify the sender immediately
and delete all copies of this message.
=======================================================
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]