Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I am trying to get a number of populated places for example for Andorra since it is a small number. Here is a geonames site with 10 places:

http://www.geonames.org/AD/largest-cities-in-andorra.html

But if I do this query:

http://api.geonames.org/search?featureCode=PPL&username=genadinik&country=AD&style=full&maxRows=100

Only 4 out of the results have population. Am I doing something wrong? Is there a more accurate way of getting populated cities there?

Thanks!

share|improve this question
    
The Data is only available for a few towns and cities - even Wolfram|Alpha is limited wolframalpha.com/entities/countries/andorra/xy/p0/k6 –  Mapperz Jun 23 '11 at 4:44
add comment

2 Answers

up vote 5 down vote accepted

The population count is simply not in the database (even though it is listed as a "populated place"). When no population count is available, you can see the XML tag:

<population/>

For example, see the edit form for Sant Joan de Caselles: GeoNames

share|improve this answer
    
thanks - is there maybe a better place to get populations of populated places? –  Genadinik Jun 23 '11 at 3:58
    
This could be difficult to track down for remote pockets of the world –  Mike T Jun 23 '11 at 4:12
    
Actually I just realized my query could be wrong as it didn't even retrieve some of the biggest cities in Andorra. So something bigger is out of whack. Could I do something with the query to make it more correct and actually get Andorra cities like Santa Coloma and Saint Julia. –  Genadinik Jun 23 '11 at 4:19
    
I'm not sure how to ORDER BY population using the web API, except to download a snapshot and load it to a local database to perform a specific query. –  Mike T Jun 23 '11 at 4:31
    
unless Andorra has a census of population and publishes the results there is probably no way to get this information. My guess would be they use a register of population instead of a census. –  iant Jun 23 '11 at 15:04
add comment

If you need populations by town in Andorra you can get them from http://www.estadistica.ad/serveiestudis/web/banc_dades4.asp?lang=4&codi_tema=2&codi_divisio=16&codi_subtemes=8 which I found by examining the footnotes on the Andorra Wikipedia page.

share|improve this answer
add comment

Your Answer

 
discard

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.