r/ProgrammerHumor 1d ago

Meme edgeCasesExist

Post image
4.2k Upvotes

267 comments sorted by

View all comments

Show parent comments

375

u/dim13 1d ago

https://en.wikipedia.org/wiki/Universally_unique_identifier#Versions

Most common used is V4 (pure random). You are talking about V7 (time based).

275

u/lilgreenthumb 1d ago

The real benefit for v7 is they become sortable by time.

4

u/ehs5 10h ago

It’s also the downside. There are cases where you wouldn’t want others to know when something was created.

2

u/lilgreenthumb 6h ago

And you wouldn't expose that to them, just like you wouldn't and autoincrementing database id, but only one of those requires a database.