How to choose between UUIDs, autoincrement/sequence keys and sequence tables for database primary keys?

Posted by Tim on Stack Overflow See other posts from Stack Overflow or by Tim
Published on 2011-01-10T00:06:40Z Indexed on 2011/01/11 19:53 UTC
Read the original article Hit count: 199

I'm looking at the pros and cons of these three primary methods of coming up with primary keys for database rows.

So assuming I am using a database that supports more than one of these methods, is there a simple heuristic to determine what the best option would be for me?

How do considerations such a distributed/multiple masters, performance requirements, ORM use, security and testing have on the choice?

Any unexpected drawbacks that one might run into?

© Stack Overflow or respective owner

Related posts about database

Related posts about database-design