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: PK with no index

Re: PK with no index

From: Connor McDonald <connor_mcdonald_at_yahoo.com>
Date: Mon, 19 Jul 1999 22:17:16 +0800
Message-ID: <3793336C.243A@yahoo.com>


Doug Cowles wrote:
>
> How can I base my primary key on an existing index?
>
> - Dc.
>
> coakleyj_at_hotmail.com wrote:
>
> > Hi Doug.
> > It is likely that the primary key has been disabled.
> > Disabling will automatically drop the corresponding
> > index (unless of course you're using Oracle 8 and you
> > based your primary key on an existing index).
> > Check the status field in the user_constraints table.
> >
> > Cheers
> > Coakleyj
> >
> > In article <37933801.1F97257B_at_bigfoot.com>,
> > Doug Cowles <dcowles_at_bigfoot.com> wrote:
> > > Found a primary key constraint on a table, let's say A.
> > > There are NO indexes on A. No Sys_C0439 blah blah,
> > > not anything. Checked DBA_INDEXES. Nothing.
> > > How can a primary key constraint exists on a table with
> > > no corresponding index of any kind? Has something gone
> > > kafluoey?
> > >
> > > - Dc.
> > >
> > >
> >
> > Sent via Deja.com http://www.deja.com/
> > Share what you know. Learn what you don't.

I think if oracle finds a unique index on the same columns (in the same order, and maybe even the same name?) then oracle will use the existing index to create the primary key constraint

HTH
--



Connor McDonald
"These views mine, no-one elses etc etc" connor_mcdonald_at_yahoo.com

"Some days you're the pigeon, and some days you're the statue." Received on Mon Jul 19 1999 - 09:17:16 CDT

Original text of this message

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