lundi 2 mars 2015

Random unguessable primary key which preserves correct order


I want primary keys in my table to be random and unguessable while still preserving correct order (order in which documents were inserted to database). Firebase uses this algorithm: http://ift.tt/1E1nSWn. Is it a good idea to port it to psql or plv8 for example and use in postgres to generate primary keys for a table? Or maybe there is other solution out of the box in PG?





Aucun commentaire:

Enregistrer un commentaire