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

0
1

I am trying to extract all "natural=tree in Bergenhus", but there are two relation called Bergenhus nested inside each other (this is how it is suposed to be). The question is how I can get data from within this multipolygon https://www.openstreetmap.org/relation/114938 and not this multipolygon https://www.openstreetmap.org/relation/6492161 with overpass turbo.

asked 21 Mar '17, 21:31

FredrikLindseth's gravatar image

FredrikLindseth
815132435
accept rate: 13%

edited 29 Mar '17, 22:00


The simplest thing is probably to set the search area directly to the relation like area(3600114938)->.searchArea;.

Working example here: http://overpass-turbo.eu/s/nGY

There's some information in the Overpass documentation about how OSM ids are mapped to Overpass area ids.

Overpass Turbo uses the public nominatim service to fill in queries like in Bergenhus, so another possibility would be to craft a search there that returned the correct place as the first result. This might be the way to go if you have other similar nested areas to deal with, though I didn't find such a phrase with a few simple tries.

permanent link

answered 22 Mar '17, 13:33

maxerickson's gravatar image

maxerickson
12.7k1083176
accept rate: 32%

A comment for future viewers: find the ID of the relation (114938 in this case) and add 3600000000 to get to the overpass area ID of 3600114938

(23 Sep '17, 18:27) FredrikLindseth

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:

×228
×18

question asked: 21 Mar '17, 21:31

question was seen: 3,823 times

last updated: 23 Sep '17, 18:27

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