Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'd like to populate a database with common location information.

I'm not entirely certain that addresses across the globe have similar or even the same entities as the Country, State, City, and Zipcode that we are so familiar with here in the United States.

Does anyone know of a web service or other method that would be useful for obtaining such data and populating a local database with its contents?

(or conversely just contacting the web service to obtain this information as needed)

share|improve this question
Online Geocoding (For Europe) -… – Mapperz Nov 23 '11 at 14:44
What about just countries, cities, states, and zips? – leeand00 Dec 3 '11 at 20:52

GeoNames has a database you can download and a web service that you could just connect to. See for an example of how to download it and load it into a postgis database.

share|improve this answer
The tld field is missing from the sql you know what data type this is supposed to be? – leeand00 Dec 3 '11 at 19:56
Actually a couple of fields from the ddl listed are missing...anything that I have below surrounded in ??? is a field missing from the ddl LOAD DATA LOCAL INFILE '/home/leeand00/geolocations/countryInfo.txt' INTO TABLE countryinfo FIELDS TERMINATED BY '\t' LINES TERMINATED BY '\n' (iso_alpha2, iso_alpha3, iso_numeric, fips_code, name, capital, areainsqk, population, continent, ???tld???, ???currency_code???, ??currency_name???, ???phone???, languages, geonameid, ???neighbours???, ???equivalent_fips_code???) – leeand00 Dec 3 '11 at 20:08
I use Postgis so I can't help with that – iant Dec 4 '11 at 20:11
Is Postgis a database? – leeand00 Dec 5 '11 at 19:37
yes - – iant Dec 6 '11 at 8:40

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.