Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: No automatic indexes

Re: No automatic indexes

From: Gints Plivna <gints.plivna_at_gmail.com>
Date: 14 Jun 2006 23:59:19 -0700
Message-ID: <1150354759.282783.207480@u72g2000cwu.googlegroups.com>


A succesful example below. And BTW it is 9.2.0.7. I assume that it could be done since the version when disabled constraints appeared. If I'm not mistaken they wasn't since the world ooops Oracle started :)

Gints Plivna
http://www.gplivna.eu/

SQL> select count(*) from user_indexes where index_name = 'PK_A';

  COUNT(*)


         0

SQL> create table a (
  2 a_id number not null,
  3 constraint pk_a primary key (a_id))   4 /

Table created.

SQL> select count(*) from user_indexes where index_name = 'PK_A';

  COUNT(*)


         1

SQL> drop table a;

Table dropped.

SQL> create table a (
  2 a_id number not null,
  3 constraint pk_a primary key (a_id) disable)   4 /

Table created.

SQL> select count(*) from user_indexes where index_name = 'PK_A';

  COUNT(*)


         0

SQL> alter table a enable constraint pk_a;

Table altered.

SQL> select count(*) from user_indexes where index_name = 'PK_A';

  COUNT(*)


         1

SQL> Received on Thu Jun 15 2006 - 01:59:19 CDT

Original text of this message

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