Hacker News new | past | comments | ask | show | jobs | submit
Sounds like the problem here is that databases need to index on more than one thing at once
It doesn’t have anything to do with indexing more than one thing.

The issue with truly random IDs is that inserts are scattered throughout the B-tree index, which cause page splits, fragmentation, and poor cache locality. Using a timestamp prefix makes new IDs sequential, so inserts tend to land near the end of the index, which avoid all the B-tree trashing and improve write performance.

loading story #50214483
They already do. UUIDv7 neatly solves a common problem: a random, unguessable, public id that works well with databaes. UUIDv4 is infamous for this.
loading story #50214265