Rebuilding a failed Index

Source: Internet
Author: User

If there is a failure index in the database, so that the failure Index table related operations in the access to the index but there is a large number of full-table scan, which is extremely resource-intensive, it must be on-line reconstruction of these failed indexes. The steps to rebuild the failed index are as follows:

1. Query database with or without a failed index

Select owner,table_name,index_name,status,last_analyzed from dba_indexes where status= ' unsable ';
2. If there is an invalid index, the index should be rebuilt online
Alter index MW_APP.IND_T_ID rebuild online;
3. Whether the query index is rebuilt well

Annotations: If the index status of the query is ' VALID ', the index has been rebuilt well.

Select owner,table_name,index_name,status,last_analyzed from dba_indexes where index_name= ' ind_t_id ';
4. Re-query the database for any invalid indexes

Annotations: The query does not have a record, indicating that there are no invalid indexes in the database, and that the failed index has all been rebuilt.

Select owner,table_name,index_name,status,last_analyzed from dba_indexes where status= ' unsable ';



Rebuilding a failed Index

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.