NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum

I have been trying to provide a polygon with an array of coordinates as a global parameter for my overpass query. But the query is through syntax error.

[bbox:poly:"50.7 7.1 50.7 7.2 50.75 7.15"];
node[amenity=cafe];
out;

Error: line 1: parse error: ',' or ']' expected - ':' found. Error: line 1: static error: A bounding box needs four comma-separated values. Error: line 1: static error: A bounding box needs four comma-separated values. Error: line 1: static error: A bounding box needs four comma-separated values. Error: line 1: parse error: ';' expected - ']' found.

Providing a bounding box instead works as expected.

[bbox:50.7,7.1,50.75,7.25];
node[amenity=cafe];
out;

It also works when the polygon is given in-line,

node[amenity=cafe](poly:"50.7 7.1 50.7 7.2 50.75 7.15");
out;

(as suggested in this tutorial)

As final attemp when below query was tried no error was given but also the result was blank.

area["50.7 7.1 50.7 7.2 50.75 7.15"];
node[amenity=cafe](area);
out;

Is it possible to give a polygon instead of bounding box as a globle parameter in an Overpass query. Could not find any documentation over the Overpass wiki pages that supports the thing I am trying here.

asked 29 Nov '18, 13:37

user1894's gravatar image

user1894
11446
accept rate: 0%

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×483
×213
×92
×65
×11

question asked: 29 Nov '18, 13:37

question was seen: 2,267 times

last updated: 29 Nov '18, 13:37

NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum