Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

overpass-turbo.eu find all cities on maps

maybe someone can help me with a overpass-turbo.eu-query.

I'd like to highlight (center of it) all cities of a country or region (or current map).

Is there maybe an "simple" example on web?

(Google was not a good friend with this special request, yet. But I am sure someone must tried to search this way already.)

Many thanks for every idea.

like image 284
FlowOver Avatar asked Sep 11 '25 02:09

FlowOver


1 Answers

Here is an example for finding all cities, towns, villages and hamlets in the country Andorra:

[out:json][timeout:25];
// fetch area “Andorra” to search in
{{geocodeArea:Andorra}}->.searchArea;
// gather results
(
  node[place~"city|town|village|hamlet"](area.searchArea);
);
// print results
out body;
>;
out skel qt;

You can view the result at overpass-turbo.eu after clicking the run button.

Note: When running this query for larger countries you might need to increase the timeout value. Also rendering the result in the browser might not be possible due to performance reasons. In this case use the export button and download the raw data instead.

like image 146
scai Avatar answered Sep 13 '25 15:09

scai