Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Oracle NULL vs '' revisited
> Loosely quoted, you stated "ISO country codes are not keys, as
> they change".
Loosely? Made up more like.
I said and I quote properly...
<START QUOTE>
"These are some examples of a natural key that have changed in the past 10
years ...
ISBN number
ISO country code
"
<END QUOTE>
And you added this "are not keys, as they change"
People tell us to use industry standard codes for natural keys - aka country, isbn etc... these have changed, unless you used a surrogate or artifical key of your own then you had to change the data.
Consider a book 'The XYZ of blah', pre ISBN change it might of been x123456 and post change it is now both x123456 and z654321 - the single title "The XYZ of blah" has two natural keys (two uniquely identifyable, verifyable keys).
DA stated this
<START QUOTE>
Natural keys can not change. If it can change IT IS NOT A KEY it is
just a value.
<END QUOTE>
The Natural key to a book is it's ISBN number, that has changed over the past 10 years.
The only thing I can interprit from this is that you guys create your own artifical key probably based on a auto incrementing number or do you like the rest of use correctly use ISBN as the natural key but create a surrogate as well and use the surrogate for table and application plumbing (foreign keys, internal values passed between the app and the db - eg. the VALUE property of the <SELECT> HTML tag.
-- Tony Rogerson, SQL Server MVP http://sqlblogcasts.com/blogs/tonyrogerson [Ramblings from the field from a SQL consultant] http://sqlserverfaq.com [UK SQL User Community]Received on Sat Aug 25 2007 - 07:40:54 CDT
![]() |
![]() |