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: sequence as primary key

Re: sequence as primary key

From: Neil C <btsscrth_at_bt.com>
Date: Mon, 11 Oct 1999 15:00:56 +0100
Message-ID: <7tsqi3$sgo$1@pheidippides.axion.bt.co.uk>


Using sequence numbers can affect the balance (right handness) of your indexes, although this has been helped in Oracle 8 with the introduction of reverse key indexes.

Deciding whether to use 2 or more columns depends on whether this helps with the cardinality of the index and / or whether it will help in resolving queries solely from the index (i.e without having to go to the table). Naturally, the size of the index will be slightly larger in order to store the values, and it may make it more likely that the index will be updated (and therefore deleted from the leaf blocks) by changes to one of the columns.

HTH NeilC

Michael Mehling wrote in message <7tsojb$97i$1_at_news.pop-stuttgart.de>...
>sequence number as primary key vs. logical primary key
>
>What are the pro's and con's of using a unique sequence number as primary
>key (like Oracle recommands)?
>What are the pro's and con's of using a primary key using 2 or more
>data-columns of a table
>
>M. Mehling
>
>
Received on Mon Oct 11 1999 - 09:00:56 CDT

Original text of this message

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