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

Hi,

With the help of this forum I found a way to retrieve the street that belongs to a specific lat/lon. I use the following code:

<osm-script output="json">
  <query type="way">
    <around lat="52.15809830545579" lon="6.402184798522356" radius="10"/>
    <has-kv k="highway" modv="" v=""/>
  </query>
  <union>
    <item/>
    <recurse type="down"/>
  </union>
  <print/>
</osm-script>

This Overpass query has got two downfalls. Not always the entire street is shown, enlarging the raduis will select more of the current street, but also results in other streets in the dataset.

What do I need to change to always get one entire street (way), even if the way is for example 1000 km long?

Anyone an idea?

asked 03 Nov '21, 22:38

Arjan's gravatar image

Arjan
11111
accept rate: 0%

Looks like I found a solution, but I don't get it to work? https://github.com/drolbr/Overpass-API/issues/95#issuecomment-291252449

(09 Feb '22, 12:48) Arjan

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:

×167
×65
×3

question asked: 03 Nov '21, 22:38

question was seen: 1,031 times

last updated: 09 Feb '22, 12:48

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