Geographic Information Systems Asked by Rudson Varona on January 4, 2021
I am new to all this stuff.
I currently want to get all the traffic signs in an area. I am running this query in overpass turbo, but nothing is returning back to me.
/*
This is an example Overpass query.
Try it out by pressing the Run button above!
You can find more examples with the Load tool.
*/
node
[traffic_signs='*']
({{bbox}});
out;
Not sure where you got that query from. I usually either go to http://overpass-turbo.eu/ and put something in the wizard ("traffic sign" works well here) or go to the openstreetmap wiki, look for the thing I am after ("traffic sign") and that gets me here https://wiki.openstreetmap.org/wiki/Key:traffic_sign and there's a link to overpass-turbo.eu that is this:
/*
This query looks for nodes, ways and relations
with the given key.
Choose your region and hit the Run button above!
*/
[out:json][timeout:25];
// gather results
(
// query part for: “traffic_sign=*”
node["traffic_sign"]({{bbox}});
way["traffic_sign"]({{bbox}});
relation["traffic_sign"]({{bbox}});
);
// print results
out body;
>;
out skel qt;
This seems to show no traffic signs in my town, although there's some in neighbouring towns so I'm sure its working. Perhaps traffic signs are badly mapped in my town.
Overpass query syntax is a bit of a mystery to me, so I'm not sure what's wrong with yours (except you have plural "traffic_signs") but even with "traffic_sign" I too get no matches. I'm not sure I understand that form of the search query - I usually get the wizards to work for me!
I think your query might be looking for a traffic sign with a name that is literally "*" - I don't see anything in the docs that says "*" is special. But a query with no "=" sign matches all:
["key"] /* filter objects tagged with this key and any value */
From https://wiki.openstreetmap.org/wiki/Overpass_API/Language_Guide
Answered by Spacedman on January 4, 2021
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP