cm0002@suppo.fi to Programming@programming.dev · 1 month agoThe perils of UUID primary keys in SQLiteandersmurphy.comexternal-linkmessage-square21linkfedilinkarrow-up144
arrow-up144external-linkThe perils of UUID primary keys in SQLiteandersmurphy.comcm0002@suppo.fi to Programming@programming.dev · 1 month agomessage-square21linkfedilink
minus-squarecalcopiritus@lemmy.worldlinkfedilinkarrow-up3·1 month agoCan’t you just reserve X bits of the primary key to store a shard ID?
minus-square8uurg@lemmy.worldlinkfedilinkarrow-up5·1 month agoYou would be inventing some style of UUID. Include a timestamp in front, so that it is sortable and you have Snowflake.
minus-squareexussum@lemmy.worldlinkfedilinkarrow-up3·1 month agoIf you are owning every little part of the design in every nuance, sure. But how do you configure this in mysqll, postgres, etc etc. does your favorite framework support this easily.
Can’t you just reserve X bits of the primary key to store a shard ID?
You would be inventing some style of UUID. Include a timestamp in front, so that it is sortable and you have Snowflake.
If you are owning every little part of the design in every nuance, sure. But how do you configure this in mysqll, postgres, etc etc. does your favorite framework support this easily.