From: Ryan Everhart <[EMAIL PROTECTED]>
Reply-To: Dallas/Fort Worth ColdFusion User Group Mailing
List<[email protected]>
To: Dallas/Fort Worth ColdFusion User Group Mailing
List<[email protected]>
Subject: Re: [DFW CFUG] Help with the "pound" character other notes
Date: Thu, 5 Jan 2006 11:36:17 -0600
Ray,
In this case you would nee to name the address variable Address again..
<cfquery datasource=-------------------------
select company, Replace(address,'##','') *AS Address*, suite, city,
state,
zip
from client
where --------------------------------------
</cfquery>
On 1/5/06, Ray Hughes <[EMAIL PROTECTED]> wrote:
>
> Hi All,
>
> The database query pulls the data for the address field.
>
> <cfquery datasource= ---------------------
> select company, address, suite, city, state, zip
> from client
> where -----------------------
> </cfquery>
>
> I have a problem with an address in the database. The problem is that
on
> some rare occasions the entry people instead of putting the suite
number
> in
> the field for the suite number they put the suite number after the
street
> address in the address field.
>
> Examples of records with good data:
> 408B Hargrove Rd E.
> 1120 NASA ROAD ONE
> 219 Billings
>
>
> Example of a record with BAD data:
> 950 W. Elliot Rd #120
>
> It seems that the "pound sign" in this field cause ColdFusion to have a
> Heart Attack.
>
> Here is the line of code I am trying to fix.
>
> Code:
>
> Line 280 <cfinput name="companyAddress" type="text" label="Address"
> width="150" value="#IIf(getProfile.recordcount neq 0,
> DE(getProfile.companyAddress), DE(fundinglogClient.address))#" />
>
> This code works fine as long as I do not access any records with bad
> address.
>
> I tried the suggestion from Ryan Everhart and this does not work.
> Unless I am doing something wrong.
>
>
> <cfquery datasource=-------------------------
> select company, Replace(address,'##',''), suite, city, state, zip
> from client
> where --------------------------------------
> </cfquery>
>
> This produces an error for line 280:
> "Element ADDRESS is undefined."
>
> Does anyone have any advice or maybe could offer some suggestions.
>
> Regards
> Ray Hughes
>
> _________________________________________________________________
> Is your PC infected? Get a FREE online computer virus scan from
McAfee(r)
> Security. http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963
>
>
> _______________________________________________
> Reply to DFWCFUG:
> [email protected]
> Subscribe/Unsubscribe:
> http://lists1.safesecureweb.com/mailman/listinfo/list
> List Archives:
> http://www.mail-archive.com/list%40list.dfwcfug.org/
> http://www.mail-archive.com/list%40dfwcfug.org/
> DFWCFUG Sponsors:
> www.HostMySite.com
> www.teksystems.com/
>
--
Ryan Everhart
[EMAIL PROTECTED]