There is a CF tag called "PreserveSingleQuotes()"

Put your string inside it like this:

WHERE Name = '#PreserveSingleQuotes(Mystring)#'

George 

gabriel bulfon wrote:
> 
> -----Mensaje original-----
> De: Bryan LaPlante [mailto:[EMAIL PROTECTED]]
> Enviado el: Thursday, February 01, 2001 7:52 PM
> Para: CF-Server
> Asunto: CFQUERY and single quotes
> 
> I am having a problem with a textarea that I use to send queries through CF
> via the CFQUERY tag.
> If I write a query that references a string value like [ select * from users
> where name = 'me' ] the database says syntax error or access violation. If
> on the other hand the query goes [ select  * from users where userID = 3 ]
> then the query runs fine.
> 
> Has anyone else found a work-a-round for this?
> 
> Bryan LaPlante
> 816-347-8220
> [EMAIL PROTECTED]
> http://www.netwebapps.com
> Web Development
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
------------------------------------------------------------------------------
To unsubscribe, send a message to [EMAIL PROTECTED] with 
'unsubscribe' in the body or visit the list page at www.houseoffusion.com

Reply via email to