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

q: primary key deferrable initially immediate

From: Ted Chyn <tedchyn_at_yahoo.com>
Date: 24 Oct 2001 17:53:12 -0700
Message-ID: <44a19320.0110241653.a442c7c@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 Wed Oct 24 2001 - 19:53:12 CDT

Original text of this message

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