Thanks Steve, I knew it was something simple.
 
Brian

________________________________

From: cfaussie@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Steve Onnis
Sent: Tuesday, 10 April 2007 1:32 PM
To: cfaussie@googlegroups.com
Subject: [cfaussie] Re: '' in SQL statement


PreserveSingleQuotes(string)

________________________________

From: cfaussie@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of KNOTT, Brian
Sent: Tuesday, 10 April 2007 1:30 PM
To: cfaussie@googlegroups.com
Subject: [cfaussie] '' in SQL statement



Whats the quickest way to remove the double ' that appears in sql
statements when you use a CF variable. 

Ie <cfset forecastDate = " 'jan-07','feb-07','mar-07' "> 

Gives me 'jan-07','feb-07','mar-07' 

When its pasted in SQL it becomes 

Select amount 
From table 
Where runDate not in (''jan-07'',''feb-07'',''mar-07'' ) 

Cf statement is 

Select amount 
From table 
Where runDate not in (#forecastDate#) 

Brian 

------------------------------------------------------------------------
----------- 

This e-mail is sent by Suncorp-Metway Limited ABN 66 010 831 722 or one
of its related entities "Suncorp". 

Suncorp may be contacted at Level 18, 36 Wickham Terrace, Brisbane or on
13 11 55 or at suncorp.com.au. 

The content of this e-mail is the view of the sender or stated author
and does not necessarily reflect the view of Suncorp. The content,
including attachments, is a confidential communication between Suncorp
and the intended recipient. If you are not the intended recipient, any
use, interference with, disclosure or copying of this e-mail, including
attachments, is unauthorised and expressly prohibited. If you have
received this e-mail in error please contact the sender immediately and
delete the e-mail and any attachments from your system. 

If this e-mail constitutes a commercial message of a type that you no
longer wish to receive please reply to this e-mail by typing Unsubscribe
in the subject line. 






--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cfaussie" group.
To post to this group, send email to cfaussie@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cfaussie?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to