If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Oracle > Disabling constraints

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-19-09, 10:26
shajju shajju is offline
Registered User
 
Join Date: Aug 2008
Posts: 340
Disabling constraints

Hi

When disabling constraints, is it important to use 'keep index'?

Would appreciate a short explanation of the consequences if we don't use 'keep index'.

Regards
Sheraz
Reply With Quote
  #2 (permalink)  
Old 07-19-09, 14:41
Littlefoot Littlefoot is offline
Lost Boy
 
Join Date: Jan 2004
Location: Croatia, Europe
Posts: 3,629
Documentation says:
Quote:
When Oracle Database uses a unique index to enforce a constraint, and constraints associated with the unique index are dropped or disabled, the index is dropped. To preserve the statistics associated with the index (because, for example, it would take a long time to re-create it), you can specify the KEEP INDEX clause on the DROP command for the constraint.
KEEP INDEX is an option; it is not obligatory so ... read some more documentation, see what each option does and which one is the best in your case.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On