Skip to main content
3 of 6
deleted 10 characters in body
Robert Harvey
  • 200.1k
  • 55
  • 468
  • 679

Primary and Foreign Keys are not supposed to be readable. Their purpose is to maintain the internal relational structure of the database, and that is all.

Naturally, if there is an appropriate natural key that will never change (I claim these are as rare as hen's teeth or four-leaf clovers, but...), you can use that, and some customers will make that one of their requirements.

But why add the additional complexity to a database system, for little appreciable benefit? Primary Surrogate keys are system-generated, guaranteed to be unique, guaranteed to never change, and are the same data type for all tables. They will have the same reliable behavior under all circumstances. Who wouldn't be in favor of that?

If you're looking for a canonical resource that supports this practice, you won't find one. There are just as many designers on the other side of the aisle that will viciously defend their use of natural, composite keys with clustered indexes, and all of the canonical resources say that it is the designer's choice.

Robert Harvey
  • 200.1k
  • 55
  • 468
  • 679