7

What is currently the highest value of OSM_ID in openstreetmapping?

What is the highest possible value of OSM_ID? 2^31 (2.147.483.648)?

And here I add some more text or my question is rejected because it is too short...

underdark
  • 84,148
  • 21
  • 231
  • 413
Uffe Kousgaard
  • 2,543
  • 15
  • 24

2 Answers2

9

The highest ID value will be different for each type of object (nodes, ways and relations) and will change from day to day as people add more objects, so knowing what it is now is of little use.

The IDs are all 64 bit signed integers at the moment, so have a theoretical limit of 2^63-1 or 9,223,372,036,854,775,807 but I think it will take a while before we get to that number.

TomH
  • 490
  • 4
  • 5
  • If we are 10 years from breaking the 2^31 barrier, it actually has a lot of use here and now. So, my question persists. For instance I have found up to 138.000.000 in the selection I am currently working with. – Uffe Kousgaard Nov 25 '11 at 10:33
3

So you can get an approximate max ID of node (around 1.5 billion, valid at the moment of writing this answer).

Also take a look at OSM stats page.

Igor Brejc
  • 3,677
  • 29
  • 28
  • Thanks to both TomH (for replying to the 2nd question) and Igor for replying to the 1st question. Unfortunately I can not mark them both as "accepted" answer. – Uffe Kousgaard Nov 25 '11 at 12:52
  • Assuming a highest ID is just wrong. Funnily enough, the node at your second link has been created just two days after your post. When handling IDs then you have to support the complete possible range. See TomH's answer for details. – scai Jul 27 '14 at 11:59
  • Nobody is assuming anything. And the answer clearly states "valid at the moment of writing this answer". Obviously the number will rise with time. – Igor Brejc Jul 27 '14 at 12:42
  • This answer is too old and not consistent. – iedmrc Sep 23 '20 at 10:28