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

I am using osmconvert to filter OSM data and convert all the ways to nodes using the --all-to-nodes parameter. When creating a new node from a way it adds 10^15 to the id of the way to make the new node's id. For what I want to use the data, I will never need to handle any ways and so was wondering wether there was a way of making the id of the new node the same as the way it was converted from? I tried to set the offset of the id by using --object-type-offset= and setting it to 0 (thinking that this would add 0 to the id and result in the same id) but this resulted in it defaulting to 10^15 once more. Does anyone know how I can solve this? Thanks, Adam

asked 07 Sep '12, 15:41

adsized's gravatar image

adsized
16112
accept rate: 0%


Nodes, ways and relations use overlapping id spaces, and ids are only unique for a given element type. In other words, it is possible that data contains both a node with the node id 4242 and a completely unrelated way with the way id 4242.

For this reason, it is not a good idea to make the node's id the same as the way it was converted from - there might already be a node using this id.

permanent link

answered 07 Sep '12, 15:50

Tordanik's gravatar image

Tordanik
12.0k15106147
accept rate: 35%

edited 07 Sep '12, 15:51

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:

×205
×47
×22
×5

question asked: 07 Sep '12, 15:41

question was seen: 4,275 times

last updated: 07 Sep '12, 15:51

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