Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

or at least newer DB file. Just thinking, is there something else being used now to figure out distances, latitudes etc. data for the US postal codes? The data file available out there is quite obsolete now ;-( Thanks

Replies are listed 'Best First'.
Re: Geo::PostalCode alternatives
by Anonymous Monk on Jun 03, 2009 at 15:11 UTC
    The data file available out there is quite obsolete now ;-( Thanks

    Its as good as it gets for free (from US gov census), though I doubt you could buy more accurate data (to confirm compare to USPS results). You can download newer files from The Zip Code Database Project

Re: Geo::PostalCode alternatives
by whakka (Hermit) on Jun 03, 2009 at 18:37 UTC
    Plotting zip codes is tricky. Here's what the Census has to say about them:

    The Census Bureau does not have maps or digital files showing the boundaries of U.S. Postal Service ZIP Codes. The fact that ZIP Codes aren't required to be polygons makes them difficult to map. They are networks of streets served by mail carriers or just individual post offices and are a tool for mail delivery. They also change periodically as required to meet Post Office operational needs. Various companies have created maps by interpolating boundaries between occurrences of ZIP Codes on the ground. However, this does not guarantee that the U.S. Postal Service delivery routes will follow this interpretation.

    The Census uses ZCTA's, which are approximations of zip codes (from 2000). I don't know how you would find zip code longitude/latitude data outside of this, though maybe it exists somewhere. You could start with the TIGER files the Census provides and then re-label the ones that have changed in the mean-time as appropriate using the USPS .xls files they publicly release. Those are available at the url pattern http://ribbs.usps.gov/files/PBZIP/$year, where $year is 2001-2009.

Re: Geo::PostalCode alternatives
by superfrink (Curate) on Jun 03, 2009 at 18:11 UTC
    There are some files for download at http://www.populardata.com/ . I don't know when the files were updated.

    http://geocoder.ca/ also has a service that will let you do lookups in real time. There is a cost. They might have a download available.
Re: Geo::PostalCode alternatives
by Anonymous Monk on Jun 04, 2009 at 11:51 UTC
    Thank you all for the tips.