471,073 Members | 1,115 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,073 software developers and data experts.

Distance Between Postal Codes

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!
Jul 23 '05 #1
4 2549
Are you in the UK? Royal Mail has some address database products that
may meet your requirements:

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

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

--
David Portas
SQL Server MVP
--

Jul 23 '05 #2
This company does mailing list software with that data in it:

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

Jul 23 '05 #3
Actually, no, I'm in North America (Canada). Sorry for not mentioning that.

"David Portas" <RE****************************@acm.org> wrote in message
news:11*********************@g14g2000cwa.googlegro ups.com...
Are you in the UK? Royal Mail has some address database products that
may meet your requirements:

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

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

--
David Portas
SQL Server MVP
--

Jul 23 '05 #4
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.

Jul 23 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

4 posts views Thread by Xenophobe | last post: by
2 posts views Thread by Galsaba | last post: by
2 posts views Thread by Axel Foley | last post: by
2 posts views Thread by Surfdog | last post: by
4 posts views Thread by Dave | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.