By the way everyone.  I used this code after doing a query of my db.  I have
three columns in the table called:
StartRange, EndRange and [The different Shipping Methods with their zones
below them] ZoneRange

Therefore, I am looking at the three variables along with the ShipZip to get
all of this info.

It ended up working great.

-----Original Message-----
From: Philip Arnold - ASP [mailto:[EMAIL PROTECTED]]
Sent: Monday, May 08, 2000 11:28 AM
To: [EMAIL PROTECTED]
Subject: RE: postal code = sector


> thanks a lot , you really save me a lot of work
> that was what I was looking for
>
> > Try the following, it worked for me.  I just got through writing a
> > shipping method for Canadian shipping.
> >
> > CFIF #Left(ShipZip,1)# EQ #Left(StartRange,1)#>
> >     <CFIF #Mid(ShipZip,2,1)# GTE #Mid(StartRange,2,1)#
> >             AND #Mid(ShipZip,2,1)# LTE #Mid(EndRange,2,1)#>
> >                     <CFIF #Mid(ShipZip,3,1)# GTE #Right(StartRange,1)#
> >                             AND #Mid(ShipZip,3,1)# LTE
> > #Right(EndRange,1)#>
> >                                     <CFSET Zone = #ZoneRange#>
> >                     </cfif>
> >     </cfif>
> > </cfif>

Please note - you don't need any of the #s in this code - unless you're
running pre-version 3.

It actually slows the code down slightly having them... it's minor, but it
does slow it down. As well as being ugly to read.

Philip Arnold
ASP Multimedia Limited
T: +44 (0)20 8680 1133

"Websites for the real world"

**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.
**********************************************************************


----------------------------------------------------------------------------
--
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.


------------------------------------------------------------------------------
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to