Maybe the 2 sets of coordinates relate to separate sides of the zip code.  
Might be more accurate although you do probably only need 1 for most uses.

----- Original Message ----
From: Christopher Jordan <[EMAIL PROTECTED]>
To: Dallas/Fort Worth ColdFusion User Group Mailing List <[email protected]>
Sent: Wednesday, March 21, 2007 8:12:24 AM
Subject: Re: [DFW CFUG] Zip code proximity

It seems I wasn't very clear. Sorry about that. :o(

@Adrian:
I found the same article. It's where I came across zipfinder.cfc

@Derek & Joe:
I know you have to use Log/Lat coordinates to get proximity. My database 
*does* have them already. The point was that Zipfinder.cfc relies upon a 
*second* set of coordinates that it calls the "RLongitude" and 
"RLatitude" *in addition to* the normal Longitude and Latitude.

I can't seem to open his included DB to see what the differences between 
RLong/RLat and Long/Lat amount to. It seems weird to me that there would 
be two sets of Long/Lat coorinates for each zip code. Everyone else 
seems to get along with only one set per zip.

I'd love any help I could get.

Here is what the current search is doing wrong:

The user asks for a 25 mile radius from zip code 12345, and it returns 
zero results. They then ask for a radius of 50 miles and the results 
contain zip codes that are within *20* miles! Those should have been in 
the search with the 25 mile radius. Hmmm...

Anyway, the other reason I thought the zipfinder.cfc would be cool was 
that it contained three or four different methods for doing this 
calculation. Some more accurate than others some faster than others. One 
of them even takes into account the curvature of the earth!

Thanks heaps for the help and support folks!

Cheers,
Chris

Joe Kelly wrote:
> As I recall, this article tells you where to get the zip code
> database.  My suggestion is to update yours with the new info
> containing the longitude and latitude.  That would be the easiest.
> 
> Otherwise you have to fix it the exisitng cfc!  I don't know how else
> you would do it unless your existing db contains some relationship
> table with zipcodes that are actually proximal (right next to each
> other).  I'd like to see the query for finding a radius of 3 zipcodes
> out!
> 
> Sounds like a new CFUG brainteaser!
> 
> Thanks,
> Joe Kelly
> 
> On 3/20/07, Adrian J. Moreno <[EMAIL PROTECTED]> wrote:
>> Found an article at CFDJ (beware auto-playing video ads)
>>
>> Building a Zip Code Proximity Search with ColdFusion
>> http://coldfusion.sys-con.com/read/154258.htm
>>
>> HTH,
>>
>> Adrian
>>
>> Christopher Jordan wrote:
>> > Hi folks,
>> >
>> > I've inherited a piece of code that does a zip code proximity search,
>> > and as it turns out: it's busted.
>> >
>> > I've been searching the web (in general) and RIAForge and CF-Talk 
>> (where
>> > there have been a couple discussions on this). Unfortunately, I've not
>> > found a solution I like. I did find something called zipfinder.cfc
>> > (which is the sort of solution I'm looking for) that was written by
>> > Robert Capili, but he includes a zip database that has a couple of
>> > fields that my existing zip database does not contain - namely the
>> > rlatitude and the rlongitude - and these are in addition to the normal
>> > latitude and longitude fields. Without these two special fields his cfc
>> > doesn't work. :o( I've emailed him to see if the component could be
>> > modified to work without these fields, but I've not heard from him yet.
>> >
>> > So I'm wonderin'... what does everyone here (whose had a need to do so)
>> > use to do proximity searches?
>> >
>> > I'm hoping for a CFC or something rather than a bunch of sql 
>> statements.
>> > I suppose that if I have to I can take some of the SQL examples that
>> > I've seen and put them into a component myself, but I'd rather not
>> > reinvent the wheel if I don't have to.
>> >
>> > What are everybody's thoughts on this subject?
>> >
>> > Cheers,
>> > Chris
>> >
>> > _______________________________________________
>> > 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.instantspot.com/
>> >  www.teksystems.com/
>> >
>> >
>>
>>
>> _______________________________________________
>> 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.instantspot.com/
>>   www.teksystems.com/
>>
> 
> _______________________________________________
> 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.instantspot.com/
>  www.teksystems.com/
> 
> 
> 

_______________________________________________
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.instantspot.com/
  www.teksystems.com/




_______________________________________________
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.instantspot.com/
  www.teksystems.com/

Reply via email to