Re: Surrogate primary key plus unique constraint vs. natural primary key: data integrity?

From: Wolfgang Keller <feliphil_at_gmx.net>
Date: Tue, 19 Mar 2013 15:54:42 +0100
Message-ID: <20130319155442.401d32cb6efe98822d584b31_at_gmx.net>


> Those people (and systems) that use surrogate keys as a matter of
> course are usually wrong, not because surrogate keys are inherently
> bad, but because those people are not aware of the implications for
> database design of using surrogate keys.

That's exactly what my own empiric experience has taught me: If they "advocate" surrogate keys by default, they don't have clue or they don't care or both. Mental lazyness.

And that's probably why my professor had told us to use natural (composite) keys by default; because then you *have to* think about *proper* unification *and* such integrity issues as the one with the overlapping foreign keys are much less likely to remain unnoticed.

Sincerely,

Wolfgang Received on Tue Mar 19 2013 - 15:54:42 CET

Original text of this message