Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Surrogate Key vs Production Key

Re: Surrogate Key vs Production Key

From: Brian Dick <bdick_at_cox.net>
Date: Fri, 8 Oct 2004 12:14:40 -0400
Message-ID: <1o4ed2618eq5e.16eck4jlizfoy$.dlg@40tude.net>


On 8 Oct 2004 05:49:30 -0700, Noons wrote:

> Daniel Morgan <damorgan_at_x.washington.edu> wrote in message news:<1097210055.635712_at_yasure>...
>

>> Joe Celko weighs in on the side of natural keys and so do I.
>> 

>
> Joe never had a client walk in and say:
>
> "you know that code of 'A/0001/sdkjskldjklsd-32998'?
> Shewt!: we mistyped it.
> Can you change it to 'A-0001/sdkjskldjklsd/32998'?
> "
>
> and suddenly he realizes that natural key is now duplicated
> in a 6 level hierarchy of tables as a FK in thousands
> of rows. Which means a major UPDATE on all those tables
> with all RI disabled. Count the downtime.
>
> Zero problem with surrogates. I'll take that anytime.
> For the cost of an extra index. Because I still have to
> see a natural key that somewhere, somehow, doesn't get
> mistyped.
>
> Errare humanum est...
> To really stuff things up, you need a natural key.

The UPDATE CASCADE option of foreign keys would ... Oh shit, Oracle doesn't support that option. :) Received on Fri Oct 08 2004 - 11:14:40 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US