17

I want to add a field to my database that stores DOIs. But I can't seem to find out what their maximum length is. Does anyone know if there is a maximum length?

Jason S
  • 184,598
  • 164
  • 608
  • 970

2 Answers2

14

From a 100K sample, I would go for 255 as max length to be on the safe side...

On the y-axis the length of the DOI and on the x-axis you have the count of DOIs. So, we have 20k DOIs out of 100K that have a DOI length of ~63 or more.

enter image description here

Renaud
  • 16,073
  • 6
  • 81
  • 79
8

never mind, I found it:

https://www.doi.org/the-identifier/resources/handbook/1_introduction#1.6.3

DOI names have two components, known as the prefix and the suffix. These are separated by a forward slash. The two components together form the DOI name:

10.1000/123456

In this example, the prefix is "10.1000" and the suffix is "123456".

There is no technical limitation on the length of either the prefix or the suffix; in theory, at least, there is an infinite number of DOI names available.

Joe
  • 46,419
  • 33
  • 155
  • 245
Jason S
  • 184,598
  • 164
  • 608
  • 970
  • I have no idea, this was at my former employer and I have no hope of remembering almost-10-year-old technical details. – Jason S Jan 12 '21 at 04:30
  • Oops, I think I looked at the edited date and not the answered date. My bad. Still brings up an interesting question -- at least for someone new to databases like me -- where the spec is so lenient and reality appears to be much more limited. – Jimbo Jan 12 '21 at 12:55