Overpass-API icon indicating copy to clipboard operation
Overpass-API copied to clipboard

Cannot get areas inside area

Open yt9tp opened this issue 5 years ago • 1 comments

Is looked at other discussions on this tic but could not resolve my problem.

I want to get all town areas within specific area. I found out that it is not possible to get areas inside area but that there is workaround.

Workarounds are based on filtering areas on other properties. I have problem that I need all areas that are place=region and have nothing else to filter them out.

I tried this:

[out:json][timeout:25]; area["ISO3166-2"="BA-SRP"] -> .country; rel(area.country)[place="town"]; map_to_area; out meta;

I got nothing.

Then i tried

[out:json][timeout:25]; area["ISO3166-2"="BA-SRP"] -> .country; rel(area.country)[place]; map_to_area; out meta;

This showed only few areas, all but one place=region. Areas place=town are missing completely. That explains why I got no areas of place=town in previous query.

This is where I got to the point I have no idea what to try more.

yt9tp avatar May 08 '19 13:05 yt9tp

Please note that this Github issue tracker is primarily intended for bug reports and enhancement requests. Your question is more of a HOWTO type which would be better served on https://help.openstreetmap.org/

You seem to assume that there are many relations with "place=town" in that area. That's not the case, most of those are in fact nodes, for which no area exists on the Overpass server. https://overpass-turbo.eu/s/IQZ

mmd-osm avatar May 09 '19 18:05 mmd-osm