Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Difference of Primary key & Unique Indexes...
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 )
They are logically the same. The relational model talks about candidate keys. A candidate key is any combination of columns that gaurantees to uniquely identify a single row. Any PK or UI is a candidate key.
> Is there any difference of performance PK and UI?
> or
> what's the particular difference of PK and UI?
The difference between PK and UI is in the RDBMS implementation. To the best of my knowledge most RDMS's automatically generate indexes based on the primary key. Hence foreign key references based on the PK should be much faster.
>
>
> Thanks in advance and mail me.
>
> ksjune_at_sys.gsnu.ac.kr
Received on Sun Jan 04 1998 - 00:00:00 CST
![]() |
![]() |