Good chance that you're using some Access reserved words, especially date
and type; you can check Access help for a list of reserved words.  Change
the names of any fields that are reserved words.

-----Original Message-----
From: Erika Foster [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, July 18, 2000 4:52 PM
To: [EMAIL PROTECTED]
Subject: Insert INTO syntax error - HELP


I can't find the syntax error in the following INSERT INTO
statement - someone with good eyes, please help me out!

<cfquery name="addrow" datasource="#dbname#">
 INSERT INTO OWS (owsid, type, date, capacity, length, width, height,
manufacturer, serial,
    discharge, repairs, repairdates, cleaning1, cleaning2, contractorname,
contractoraddress,
    contractorPOC, contractorphone, license, sludge, sample, locationid,
siteid)

VALUES ('#thisowsid#', '#thistype#', '#thisdate#', '#thiscapacity#',
'#thislength#',
     '#thiswidth#', '#thisheight#', '#thismanufacturer#', '#thisserial#',
'#thisdischarge#',
     '#thisrepairs#', '#thisrepairdates#', '#thiscleaning1#',
'#thiscleaning2#', '#Thiscontractorname#',
     '#thiscontractoraddress#', '#thiscontractorPOC#',
'#thiscontractorphone#', '#thislicense#',
     '#thissludge#', '#thissample#', '#thislocationid#', '#thissiteid#')
  </cfquery>

gives this result with dummy data:

[Microsoft][ODBC Microsoft Access Driver] Syntax error in INSERT INTO
statement.


SQL = "INSERT INTO OWS (owsid, type, date, capacity, length, width, height,
manufacturer, serial, discharge, repairs, repairdates, cleaning1, cleaning2,
contractorname, contractoraddress, contractorPOC, contractorphone, license,
sludge, sample, locationid, siteid) VALUES ('1', 'jkl', 'jkl', 'jkl', 'jk',
'jk', 'jk', 'jk;', 'jkl', 'jk', 'jk', 'jk', 'jk', 'jk', 'jk', 'jk', 'jk',
'jk', 'jk', 'jk', 'jk', '02', '27A25')"



Thanks for you help!


Erika Foster
engineering-environmental Management
Applications Developer
(505) 866-1654
[EMAIL PROTECTED]

----------------------------------------------------------------------------
--
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.
------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to