Hi all,
can someone give me a hint my overpass query does not return the Wikidata property for “Wahlstedt” even so Wahlstedt has one?
[out:json];
(
node(around:10000.0,53.9528,10.2099)["place"="town"];
);
(._;>;);
out;
https://www.openstreetmap.org/relation/422875
Thank you for your help.
OK. Got it.
But how can I search for this particular Relation as “rel” is not showing it as a result
You’re now searching for nodes with a place=town tag. If you’re looking for relations, you do something like relation(around:10000.0,53.9528,10.2099)[“place”=“town”];
Since this relation does not have a place=town key, you will get no results. You probably want something like
[out:json];
(
relation(around:10000.0,53.9528,10.2099)["admin_level"="8"];
);
(._;>;);
out;
This will give all admin_level 8 borders. Then you have to look for Wahlstedt to get the wikidata.
So maybe do something like this directly
[out:json];
(
relation(around:10000.0,53.9528,10.2099)["admin_level"="8"]["name"="Wahlstedt"];
);
(._;>;);
out;