Home > Archive > Microsoft SQL Server forum > July 2005 > Distance Between Postal Codes









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Distance Between Postal Codes
Dave \IT\

2005-06-29, 11:23 am

I'm looking to find out how I'd go about setting up a database where a
visitor to my site could punch in their postal code, and find out how far
they are from another postal code. For example, AutoTrader has this feature
I believe to tell you how far the vehicle is from you. Dating sites have
them so you can do proximity searches.

Anyone have any ideas where I could start? I'm thinking the post office,
but if anyone else has suggestions, I'm open to hear them.

Thanks!


David Portas

2005-06-29, 11:23 am

Are you in the UK? Royal Mail has some address database products that
may meet your requirements:

http://www.royalmail.com/portal/rm/...40085&gear=shop

Other solutions exist too:
http://www.google.co.uk/search?biw=... /> 7CcountryGB

--
David Portas
SQL Server MVP
--

--CELKO--

2005-06-29, 1:24 pm

This company does mailing list software with that data in it:

http://www.melissadata.com/Lookups/

Dave \IT\

2005-06-29, 1:24 pm

Actually, no, I'm in North America (Canada). Sorry for not mentioning that.

"David Portas" < REMOVE_BEFORE_REPLYI
NG_dportas@acm.org> wrote in message
news:1120060282.670987.93490@g14g2000cwa.googlegroups.com...
> Are you in the UK? Royal Mail has some address database products that
> may meet your requirements:
>
> http://www.royalmail.com/portal/rm/...40085&gear=shop
>
> Other solutions exist too:
> http://www.google.co.uk/search?biw=... /> 7CcountryGB
>
> --
> David Portas
> SQL Server MVP
> --
>



Terri

2005-07-01, 8:23 pm

Be aware of the limitations of these calculations. I have done something
similar with US zipcodes, same principle. Each zone has a latitude and
longitude associated with it. This point is known as a centroid which is a
representative point for the whole zone. If the zone is a square or a circle
the centroid would be right in the middle. For a very irregular zone the
centroid might not even be in the zone. Think of a doughnut shaped zone.

Then you calculate the distance between the 2 centroids. Imagine 2 100 mile
square zones side by side. The distance calculation would be 100 miles. The
2 interested parties could actually be across the street from each other
each in their own zone.





Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2009 droptable.com