This is a static archive of our old OpenStreetMap Help Site. Please post any new questions and answers at community.osm.org.

get all the node using poly Recurse

0

hi I'm using overpass turbo and im trying to get all the node in this bounded box using recurse poly I tried this code

//[out:json][timeout:25][bbox:40.73112,-73.89061,40.73391,-73.88807];
way(poly:"40.73112,-73.89061,40.73391,-73.88807")
node(w);
out center;

but it gives me an error how can I solve it

asked 03 Jan '21, 07:23

rabeeqasem's gravatar image

rabeeqasem
318811
accept rate: 0%


2 Answers:

1

In the future, when asking for help it is generally good to specify exactly what the error message is that you receive, rather than "it gives me an error".

You say you want to get all the nodes in a given bounding box.

The query to use for that would be

node  (40.73112,-73.89061,40.73391,-73.88807);
out;

No ways or recursion involved.

answered 03 Jan '21, 14:08

Frederik%20Ramm's gravatar image

Frederik Ramm ♦
82.5k927201273
accept rate: 23%

0

Your solution is provided in the error dialog: "at least 3 lat/lon float value pairs must be provided.", but you don't need it. If you want nodes of ways:

[bbox:40.73112,-73.89061,40.73391,-73.88807];
way;
node(w);
out;

Else use Fredrik's solution.

Plus you were missing a semicolon.

answered 03 Jan '21, 14:34

DaveF's gravatar image

DaveF
3.3k8498133
accept rate: 16%

Source code available on GitHub .