perhaps you could post the code you're using. we could take a look.
chris olive, cio
cresco technologies
[EMAIL PROTECTED]
http://www.crescotech.com
-----Original Message-----
From: Diana Nichols [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 25, 2001 9:42 AM
To: CF-Talk
Subject: ' in SQL 2000
I'm having a frustrating problem....
I have several queries in which I'm composing the SQL statement and then
inserting it into the query through a variable (Necessary because I'm
looping through a list to get the fieldnames and values).
e.g.: <cfset list1="#field1#, #field2#"><cfset list2=" '#value1#',
'#value2#' ">
then in the query:
insert into table1(#list1#)
values (#list2#)
When I output the generated SQL, it looks perfect....but SQL seems to be
having a problem with the ' (single quotes) surrounding strings ....I've
tried preservesinglequotes(), using chr(39), etc.......and I still get
syntax errors on insert or update. When I take the output data and manually
insert it into the query, it works fine - eliminating the possibility of
data type errors.
I've tried this with 4 different queries, with the same results.
I've now run out of things to try......Ideas?
TIA!
D
*************
Diana Nichols
Webmistress
http://www.lavenderthreads.com
770.434.7374
"One man's magic is another man's engineering." ---Lazarus Long
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists