Here is the code. This is all in a cfloop....

<cfset county = "0">
<cfset cip_numb = "">
<cfloop query="get_cip_num">                                            
<cfif county eq "0">
<cfset cip_numb = "cip = #get_cip_num.cip_number#">
<cfelse>
<cfset cip_numb = "#cip_numb# or cip = #get_cip_num.cip_number#">
</cfif>
<cfset county = county + 1>
</cfloop>        


<cfquery datasource="#datasource#" name="count1" dbtype="odbc">
select count(prop_id) as count1 from vw_proposal_all where 
<cfif fice contains "all">
<cfelse>
<cfset fice_counter = 0 >
(
        <cfloop list="#aList#" index="new_fice" delimiters=",">
        fice = #new_fice# <cfif fice_counter eq
list_length><cfelse>or</cfif>
        <cfset fice_counter = fice_counter + 1>
        </cfloop>
)
and 
</cfif>
application_date >= #from_date# and application_date <= #to_date# and 
(#cip_numb#)
</cfquery>

-----Original Message-----
From: Raymond Camden [mailto:jedimaster@;macromedia.com] 
Sent: Tuesday, November 12, 2002 2:59 PM
To: CF-Talk
Subject: RE: Single quotes trouble...


Ah- you are passing it to SQL? Can you show us all of your code?

=======================================================================
Raymond Camden, ColdFusion Jedi Master for Hire

Email    : [EMAIL PROTECTED]
WWW      : www.camdenfamily.com/morpheus
Yahoo IM : morpheus

"My ally is the Force, and a powerful ally it is." - Yoda 

> -----Original Message-----
> From: Wurst, Keith D. [mailto:wurst@;rti.org]
> Sent: Tuesday, November 12, 2002 2:55 PM
> To: CF-Talk
> Subject: RE: Single quotes trouble...
> 
> 
> I've tried that and it's showing up as double quotes -
> causing the sql query
> to fail.
> 
> -----Original Message-----
> From: Scott Brady [mailto:cf_talk@;scottbrady.net]
> Sent: Tuesday, November 12, 2002 2:50 PM
> To: CF-Talk
> Subject: Re: Single quotes trouble...
> 
> 
> ><cfset cip_numb = "cip = #get_cip_num.cip_number#">
> >
> >I would like to put the single quotes around the
> >#get_cip_num.cip_number#.
> 
> If I understand the question, have you tried:
> 
> <cfset cip_numb = "cip = '#get_cip_num.cip_number#'">
> 
> ?
> 
> Scott
> 
> --------------------------------
> Scott Brady
> http://www.scottbrady.net/
>  
>              
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Get the mailserver that powers this list at http://www.coolfusion.com

Reply via email to