You could be getting the same error, except as a result of an incorrect data
type on a different column. For example, if Location is a number code, and
LocationDescription is a text field, then the following would generate your
error message because of the presence of quote marks (only for text strings)
on the first variable...

'#Location#'
'#LocationDescription#'

Then if you decided "Oh it's those quote marks causing the problem" and
removed them, you'd get the same error again because the database would
think you were trying to write a number to a text field
(LocationDescription), like this ...

#Location#
#LocationDescription#

So the solution is to find out exactly what the data type is for each of
those columns in the database. If your ColdFusion Studio connects to your
database, it should be relatively easy. Text strings (including alphanumeric
fields) get quote marks, numbers do not. Good luck!

Keith Purtell, Web/Network Administrator
VantageMed Operations (Kansas City)
Email:  [EMAIL PROTECTED]

CONFIDENTIALITY NOTICE: This email message, including any attachments, is
for the sole use of the intended recipient(s) and may contain confidential
and privileged information. Any unauthorized review, use, disclosure or
distribution is prohibited. If you are not the intended recipient, please
contact the sender by reply email and destroy all copies of the original
message.


-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
Behalf Of Richard Morrison
Sent: Tuesday, March 26, 2002 7:44 AM
To: [EMAIL PROTECTED]
Subject: Re: [KCFusion] Can someone tell me what the hells wrong with
this sql statement


actually it does, for some reason the syntax error is in the the sql ,
I tried encasing with single quotes , double quotes , nothing is working, i
keep  getting the same stupid error



ODBC Error Code = 37000 (Syntax error or access violation)
[Microsoft][ODBC Microsoft Access Driver] Syntax error in INSERT INTO
statement.
SQL = "insert into test3
(Area,GeoMarket,Ctry,Location,LocationDescription,Family,Subfamily,Tag,Group
,AssetDescription,Co,Rig,Quantity,Approval,Manufacturer,Model,Serial,PO,Serv
DateMMYY,FA_TC01,FA_TC02,FA_TC03,FA_TC04,FA_TC05,FA_TC06,FA_TC07,FA_TC08,FA_
TC09)
values( '?' , '?' , '?' , '?' , '?' , '?' , '?' , '?' , '?' , '?' , '?' ,
'?' , '?' , '?' , '?' , '?' , '?' , '?' , '?' , '?' , '?' , '?' , '?' , '?'
, '?' , '?' , '?' , '?' )"
Query Parameter Value(s) -
Parameter #1 = aa
Parameter #2 = aa
Parameter #3 = aa
Parameter #4 = aa
Parameter #5 = aa
Parameter #6 = aa
Parameter #7 = aa
Parameter #8 = aa
Parameter #9 = aa
Parameter #10 = aa
Parameter #11 = XE
Parameter #12 = aa
Parameter #13 = aa
Parameter #14 = aa
Parameter #15 = aa
Parameter #16 = aa
Parameter #17 = aa
Parameter #18 = aa
Parameter #19 = aa
Parameter #20 = aa
Parameter #21 = aa
Parameter #22 = aa
Parameter #23 = aa
Parameter #24 = aaa
Parameter #25 = aa
Parameter #26 = aa
Parameter #27 = aaa
Parameter #28 = aa
Data Source = "TEST"


At 07:42 AM 3/26/2002 -0600, you wrote:
>Will the database allow a null insert ? Check your table that your
inserting
>to and make sure you have the ability to insert a null value.
>----- Original Message -----
>From: "Richard Morrison" <[EMAIL PROTECTED]>
>To: <[EMAIL PROTECTED]>
>Sent: Tuesday, March 26, 2002 7:02 AM
>Subject: RE: [KCFusion] Can someone tell me what the hells wrong with this
>sql statement
>
>
> > oh, actually it doesnt work if there are some null values in the list:
> >
> > heres a samle list that causes an error:
> >
> > LAM,,,,VEN EAST OFFICE
> > LAM,VTT,,,
> >
> > how can i solve this problem?
> >
> >
> >
> > At 06:33 AM 3/26/2002 -0600, you wrote:
> > >Richard,
> > >
> > >Check your insert statement for proper use of quotes.  Whenever you are
> > >inserting/updating, or selecting on a string (versus numeric) type of
> > >field, your field values must be specified inside of quotes.  Even
> > >though it looks like you are using parameters, you probably need to
have
> > >something like:  values("#parameter1#",....
> > >
> > >Ryan
> > >
> > >-----Original Message-----
> > >From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] On
> > >Behalf Of Richard Morrison
> > >Sent: Tuesday, March 26, 2002 5:12 AM
> > >To: [EMAIL PROTECTED]
> > >Subject: [KCFusion] Can someone tell me what the hells wrong with this
> > >sql statement
> > >
> > >
> > >ODBC Error Code = 37000 (Syntax error or access violation)
> > >[Microsoft][ODBC Microsoft Access Driver] Syntax error in INSERT INTO
> > >statement.
> > >SQL = "insert into test (Area, GeoMarket, Ctry, Location,
> > >LocationDescription, Family, Subfamily, Tag, Group, AssetDescription,
> > >Co,
> > >Rig, Quantity, Approval, Manufacturer, Model, Serial, PO, ServDateMMYY,
> > >FA_TC01, FA_TC02, FA_TC03, FA_TC04, FA_TC05, FA_TC06, FA_TC07, FA_TC08,
> > >FA_TC09) values( ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ?
,
> > >?
> > >, ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? , ? )"
> > >Query Parameter Value(s) -
> > >Parameter #1 = LAM
> > >Parameter #2 = VTT
> > >Parameter #3 = VEN
> > >Parameter #4 = 58258
> > >Parameter #5 = VEN EAST OFFICE
> > >Parameter #6 = 1
> > >Parameter #7 = 1
> > >Parameter #8 = 2
> > >Parameter #9 = WL
> > >Parameter #10 = VEHICLE TOYOTA 4X4 PU PC LONG
> > >Parameter #11 = XE
> > >Parameter #12 = 258
> > >Parameter #13 = 1
> > >Parameter #14 = TRN IN GEC
> > >Parameter #15 = 1
> > >Parameter #16 = 3
> > >Parameter #17 = 3
> > >Parameter #18 = 3
> > >Parameter #19 = 297
> > >Parameter #20 = 3
> > >Parameter #21 = 3
> > >Parameter #22 = 3
> > >Parameter #23 = 3
> > >Parameter #24 = 3
> > >Parameter #25 = 3
> > >Parameter #26 = 3
> > >Parameter #27 = 3
> > >Parameter #28 = 3
> > >Data Source = "1"
> > >
> > >
> > >
> > >
> > >______________________________________________________________________
> > >The KCFusion.org list and website is hosted by Humankind Systems, Inc.
> > >List Archives........ http://www.mail-archive.com/cf-list@kcfusion.org
> > >Questions, Comments or Glowing Praise.. mailto:[EMAIL PROTECTED]
> > >To Subscribe.................... mailto:[EMAIL PROTECTED]
> > >To Unsubscribe................ mailto:[EMAIL PROTECTED]
> > >
> > >
> > >
> > >
> > >
> > >
> > >______________________________________________________________________
> > >The KCFusion.org list and website is hosted by Humankind Systems, Inc.
> > >List Archives........ http://www.mail-archive.com/cf-list@kcfusion.org
> > >Questions, Comments or Glowing Praise.. mailto:[EMAIL PROTECTED]
> > >To Subscribe.................... mailto:[EMAIL PROTECTED]
> > >To Unsubscribe................ mailto:[EMAIL PROTECTED]
> > >
> >
> >
> >
> >
> > ______________________________________________________________________
> > The KCFusion.org list and website is hosted by Humankind Systems, Inc.
> > List Archives........ http://www.mail-archive.com/cf-list@kcfusion.org
> > Questions, Comments or Glowing Praise.. mailto:[EMAIL PROTECTED]
> > To Subscribe.................... mailto:[EMAIL PROTECTED]
> > To Unsubscribe................ mailto:[EMAIL PROTECTED]
> >
> >
> >
>
>
>
>______________________________________________________________________
>The KCFusion.org list and website is hosted by Humankind Systems, Inc.
>List Archives........ http://www.mail-archive.com/cf-list@kcfusion.org
>Questions, Comments or Glowing Praise.. mailto:[EMAIL PROTECTED]
>To Subscribe.................... mailto:[EMAIL PROTECTED]
>To Unsubscribe................ mailto:[EMAIL PROTECTED]
>




______________________________________________________________________
The KCFusion.org list and website is hosted by Humankind Systems, Inc.
List Archives........ http://www.mail-archive.com/cf-list@kcfusion.org
Questions, Comments or Glowing Praise.. mailto:[EMAIL PROTECTED]
To Subscribe.................... mailto:[EMAIL PROTECTED]
To Unsubscribe................ mailto:[EMAIL PROTECTED]


 
 
______________________________________________________________________
The KCFusion.org list and website is hosted by Humankind Systems, Inc.
List Archives........ http://www.mail-archive.com/cf-list@kcfusion.org
Questions, Comments or Glowing Praise.. mailto:[EMAIL PROTECTED]
To Subscribe.................... mailto:[EMAIL PROTECTED]
To Unsubscribe................ mailto:[EMAIL PROTECTED]
 

Reply via email to