Example: Deleting an Index

If you no longer need an index, then you can delete it using SQL Developer.

In this example, you delete the PROD_DESC_IDX index that you created previously on the SH.PRODUCTS table in "Example: Creating an Index".

Note:

You cannot delete an index that is currently used to enforce a constraint. You must disable or delete the constraint and then, if the index is not deleted as a result of that action, delete the index.

To delete the description index on the SH.PRODUCTS table:

  1. In SQL Developer, view the tables in the SH schema, by following the instructions in "Viewing Tables".
  2. Right-click the PRODUCTS table, and select Index, and then Drop.

    The Drop dialog box appears, with the Prompts tab displayed.

  3. In the Drop Index field, select PROD_DESC_IDX.
  4. Click Apply.

    A confirmation message appears.

See Also:

"About Indexes"