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 -> Preferred method in creating primary key

Preferred method in creating primary key

From: Norman Dunbar <Norman.Dunbar_at_lfs.co.uk>
Date: Wed, 13 Aug 2003 12:53:48 +0100
Message-ID: <E2F6A70FE45242488C865C3BC1245DA70410C4B7@lnewton.leeds.lfs.co.uk>


Hi Jack,

my favourite method is this :

create table blah (.....)
create index blah_pk on blah (...)
alter table blah add constraint blah_pk primary key (...) deferrable initially immediate;

Now I can drop my constraint without losing my index.

You mentioned that your index was hidden when you dropped or disabled the constraint - it isn't hidden, it is quietly dropped. That's what it 'comes back' in the default tablespace.

Cheers,
Norm.



Norman Dunbar
Database/Unix administrator
Lynx Financial Systems Ltd.
mailto:Norman.Dunbar_at_LFS.co.uk
Tel: 0113 289 6265
Fax: 0113 289 3146
URL: http://www.Lynx-FS.com

-------------------------------------
Received on Wed Aug 13 2003 - 06:53:48 CDT

Original text of this message

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