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

I have a relation, and need to get its ways along with role (inner/outer) and node IDs.

If I make this query:

[out:json]; rel(16357218); out geom;

I get type, ref, role, geometry for each member (but no nodes IDs).

If I make this query:

[out:json]; rel(16357218); way(r); out geom;

I get nodes for each way, but no role.

How can I get both fields for each way, given relation ID?

asked 22 Sep '23, 06:54

Oleg%20V9's gravatar image

Oleg V9
26112
accept rate: 0%


I solved this issue with the following query:

[out:json]; rel(16357218); out; way(r); out geom;

permanent link

answered 22 Sep '23, 08:38

Oleg%20V9's gravatar image

Oleg V9
26112
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:

×236
×205
×167
×28
×12

question asked: 22 Sep '23, 06:54

question was seen: 777 times

last updated: 22 Sep '23, 08:38

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