Created
September 5, 2019 00:17
-
-
Save Nate-Wessel/7f74baaad95f847786e0e1ada5527b97 to your computer and use it in GitHub Desktop.
Overpass query to select buildings in hamilton county not recently edited.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[timeout:600]; | |
// Hamilton County area by id | |
rel(104784); map_to_area->.ham; | |
// get older buildings inside the county | |
way(area.ham)[building](if: timestamp() < "2014-08-25")->.buildings; | |
// iterate over buildings, checking the dates on their nodes | |
foreach .buildings->.way { | |
// only add ways to the result set if nodes are also | |
// not recently modified | |
node(w.way)(if: timestamp() > "2014-08-25"); | |
if (count(nodes) == 0) { | |
( .way; .result; )->.result; | |
} | |
} | |
// recurse to include nodes of ways | |
(.result;>;); | |
out body; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment