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: rebuild PK index

Re: rebuild PK index

From: James Lorenzen <james_lorenzen_at_allianzlife.com>
Date: Wed, 27 Oct 1999 21:04:32 GMT
Message-ID: <7v7pcu$i4l$1@nnrp1.deja.com>


To "drop" a PK index, "ALTER TABLE xxxxx DROP PRIMARY KEY;" You need to alter tble to add the PK constraint back. The index may be built by the alter table command or you may create the index first.

If you just need to rebuild to "clean up" the index, the "ALTER INDEX xxx REBUILD TABLESPACE xxx {optionally other storage options}". This command will default to teh users default tablespace and the storage defaults of that tablespace.

HTH
    James

In article <381736B9.FC550D89_at_Alliedsignal.com>,   Naushi Hussain <Naushi.Hussain_at_Alliedsignal.com> wrote:
> Oracle 7.3.4 How do you rebuild an index on PK. I tried through
Entprize
> Manager but said 'cant drop a PK'
>
> any suggestions will be appreciated
>
>

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Wed Oct 27 1999 - 16:04:32 CDT

Original text of this message

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