Hi
I'm selecting How do I check if the In this example:
http://overpass-turbo.eu/s/zRH
Edit: I spotted an error I my code, now rectified, but it doesn't help with the solution. asked 26 Jun '18, 17:17 DaveF |
NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum
Hi
I'm selecting How do I check if the In this example:
http://overpass-turbo.eu/s/zRH
Edit: I spotted an error I my code, now rectified, but it doesn't help with the solution. asked 26 Jun '18, 17:17 DaveF |
Once you sign in you will be able to subscribe for any updates here
By RSS:Markdown Basics
Question tags:
question asked: 26 Jun '18, 17:17
question was seen: 1,356 times
last updated: 27 Jun '18, 17:15
NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum
(.TStats out geom;)
will output all members of the .TStats set, so the script will currently output the whole set for each one that matches the test.I see. So is there a way to get the individual element of .TStats being processed by the foreach loop?
Yep, take a look at https://wiki.openstreetmap.org/wiki/Overpass_API/Overpass_QL#For-each_loop_.28foreach.29 it shows how to name the loop variable.
I experimented a bit, the current test doesn't work with the variable fixed.
Note I've updated the OP routine To test, I simplified the routine a bit: http://overpass-turbo.eu/s/zSZ I've made it more verbose than it needs to be, to hopefully make it clearer. if you look on the data tab Tottenham shouldn't be displaying as the way count is 0. It seems to me the
if:count(ways)
line isn't filtering, but I'm unsure why. I took it from : https://wiki.openstreetmap.org/wiki/Overpass_API/Overpass_API_by_Example#Isolated_Buildings. ----- Sorry, which variable shouldn't be fixed?By variable fixed I meant I experimented with the initial script after correcting the issue with the looping variable.