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: primary key deferrable initially immediate

Re: primary key deferrable initially immediate

From: Howard J. Rogers <howardjr_at_www.com>
Date: Thu, 25 Oct 2001 18:27:52 +1000
Message-ID: <3bd7cad3$0$9827$afc38c87@news.optusnet.com.au>


All perfectly normal. Check out my site, find "tips", "Administration", and check out the paper for primary key constraints and what you should know about them.

Regards
HJR

--

Oracle Resources : http://www.geocities.com/howardjr2000
========================================


"Ted Chyn" <tedchyn_at_yahoo.com> wrote in message
news:44a19320.0110241653.a442c7c_at_posting.google.com...

> all,
>
> Is the following listing an expected behavoir for primary key ?
>
> what is 'defferrable initially immediate' to primary constraint and index
?
>
> thnx ted chyn
>
>
> SQL> create table t
> 2 ( x int,
> 3 constraint t_pk primary key (x)
> 4 deferrable initially immediate );
>
> Table created.
>
> SQL> select index_name from user_indexes where table_name='T';
>
> INDEX_NAME
> ------------------------------
> T_PK
>
> SQL> alter table t drop constraint t_pk;
>
> Table altered.
>
> SQL> select index_name from user_indexes where table_name='T';
>
> INDEX_NAME
> ------------------------------
> T_PK ### note index still here
>
> =================
> SQL> create table q (a number, constraint pk_q primary key (a));
>
> Table created.
>
> SQL> select index_name from user_indexes where table_name='Q';
>
> INDEX_NAME
> ------------------------------
> PK_Q
>
> SQL> alter table q drop constraint pk_q;
>
> Table altered.
>
> SQL> select index_name from user_indexes where table_name='Q';
>
> no rows selected #### note index is gone when primary key
constraints
> is dropped.
Received on Thu Oct 25 2001 - 03:27:52 CDT

Original text of this message

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