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: Difference of Primary key & Unique Indexes...

Re: Difference of Primary key & Unique Indexes...

From: Scott Cooper <tedscott_at_sympatico.ca>
Date: 1998/01/09
Message-ID: <34B6B25D.A00C92E8@sympatico.ca>#1/1

In general, use primary key constraints when setting up you integrity constraints. In order to define a foreign key constraint on a detail table, you first need a primary key constraint on the master table. If, after this, you require additional uniqueness within your table, use the unique key constraint. As others have noted, you may need to use a UK if your "primary key" needs to support nulls.

Ted
cucu_at_nongae.gsnu.ac.kr wrote:

> Hi everybody...
>
> I'd like to know the difference of Primary Key and Unique Index.
> (PK : Primary Key, UI : Unique Index )
> Is there any difference of performance PK and UI?
> or
> what's the particular difference of PK and UI?
>
> Thanks in advance and mail me.
>
> ksjune_at_sys.gsnu.ac.kr
Received on Fri Jan 09 1998 - 00:00:00 CST

Original text of this message

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