You can't change the comma delimiter from submitted form values, but you
can use your own delimiter, such as the pipe "|", when creating your
select box.

Then, the user selects multiple addresses such as:
French Lick|IN,Evansville|IN,Houston|TX

Then, when you perform the query, you can replace "|" with a comma (and
space) as needed.

M!ke 

-----Original Message-----
From: Greg Morphis [mailto:[EMAIL PROTECTED] 
Sent: Monday, January 03, 2005 12:45 PM
To: CF-Talk
Subject: comma separator

I have a query in which a list (selected from items in a select box) are
searched by. My problem stems from the fact that this list contains
City, St and these are being counted as 2 enteries, not 1. Is there a
way to change the default separator for a select box or does anyone have
any other suggestions? Query follows.

                        SELECT 
                                b.CONTRACTMARKET,b.CHANNEL,b.AGENTNAME,
a.CONTRACTCONTACTNAME,
                                a.CONTRACTADDRESS, a.CONTRACTCITY,
a.CONTRACTSTATE, a.CONTRACTZIP, 
                                b.COMMISSIONTYPE, b.AGREEMENTNAME,
to_char(b.STARTDATE,'mm/dd/yyyy') as STARTDATE, c.TERRITORIES,
                                b.ACCOUNTMANAGER

                        from agentinfo a, contractinfo b, TERRITORIES c
                        where a.agentid = b.agentid(+)
                        AND b.contractid = c.contractid(+)
                        <cfif arguments.mkt neq "all">
                                AND lower(contractmarket) in
(<cfqueryparam cfsqltype="CF_SQL_VARCHAR" value="#lcase(arguments.mkt)#"
list="Yes">)
                        </cfif>


--
Auxilium meum a Domino



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Special thanks to the CF Community Suite Gold Sponsor - CFHosting.net
http://www.cfhosting.net

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:189165
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to