Re: Surrogate Keys

From: Ray DiMarcello <rdimarcello_at_ingva.com>
Date: 2000/05/30
Message-ID: <8h19qn$ah1$1_at_bob.news.rcn.net>#1/1


Might it not waste more space by propogating a multi-column key to other tables (as foreign keys) where that data really isn't needed, but the relationship is?

Like anything else it's case by case ... I wouldn't run out and replace all of my "realkey"s with surrogate keys for no good reason, but this construct does have some value. And not everyone is using the product that you consider to have the best implementation of surrogate keys.

RD

>
>A true surrogate key would be maintained by the system and not exposed
>to the users. What you have is an artifacial key that messes up the
>system. I have see people write stuff liek this:
>
> CREATE TABLE Foobar
> (seqkey IDENTITY PRIMARY KEY,
> realkey1 INTEGER NOT NULL,
> realkey2 INTEGER NOT NULL,
> UNIQUE (realkey1, realkey2),
> ...);
>
>but all this does is waste space.
>
>
>--CELKO--
>Joe Celko, SQL and Database Consultant
>
Received on Tue May 30 2000 - 00:00:00 CEST

Original text of this message