i use this query at the time and i need to extend this with the output of the "region" too:
how can i do that? asked 23 Oct '19, 13:42 n00bster |
Likely something like https://wiki.openstreetmap.org/wiki/Overpass_API/Overpass_API_by_Example#Adding_Georeference_details_to_village_nodes_.28since_0.7.54.29 You can use a foreach loop to amend each item, but beware that such queries will likely be rejected if there are a lot of items to amend. answered 23 Oct '19, 15:16 maxerickson i have run this example, but there is not the "region" > "Randgebirge östlich der Mur" what i would need.
(23 Oct '19, 15:47)
n00bster
Indeed, the example illustrates the general technique of modifying a result with information from an enclosing area rather than exactly solving your specific request. You'll need to modify the internal part of the foreach loop to find the region rather than administrative boundaries in general.
(23 Oct '19, 17:03)
maxerickson
|
I'm unsure what you're trying to achieve. There are no 'region' tags in the data you're returning. Isn't Gratkorn the region?
[out:csv(::id, ::lat, ::lon, "name", ele, "region"; true; ",")]; {geocodeArea:Gratkorn}}; node[natural=peak][name]ele; out center;
if i run the query i get some results of peaks, as sample this one: https://www.openstreetmap.org/query?lat=47.14775&lon=15.37002 called "Weißegg", when i do a right click for a "objectcall" i see that this peak have a relation with the region "Randgebirge östlich der Mur". exactly this regions i would need to output to very peak what i generate in my query.