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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Inserting a new PK into an existing table

Re: Inserting a new PK into an existing table

From: David Newman <dnewman_at_maraudingpirates.org>
Date: 31 Aug 2006 13:57:20 -0400
Message-ID: <f6wwt8olren.fsf@BOS004777.na.pxl.int>


"Mark D Powell" <Mark.Powell_at_eds.com> writes:

> Jens Lenge wrote:
>
> Normally we use a business column or set of column values in the table
> to be the PK and do not use an artificial key since if a unique
> business value exists there is no need for or real use of an artificial
> key.
>

This is an interesting subject to me. Normally I would fully agree with you. But I have been learning the Hibernate persistence library lately and they refer to this type of model, one in which actual business columns are used in the primary key, as "legacy" and not designed well and that an artificial primary key is always preferred. I've always felt that if you are going to have something in the table, like an employee id or SSN, that is going to have a unique constraint on it anyway you might as well make it the primary key. Is this some new way of thinking?

--
Dave Newman
Received on Thu Aug 31 2006 - 12:57:20 CDT

Original text of this message

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