Hitachi

Hitachi Advanced Database Setup and Operation Guide


11.3.9 Deleting an index

To delete an index (B-tree index, text index, or range index) defined for a table, execute the DROP INDEX statement.

For details about the DROP INDEX statement, see DROP INDEX (delete an index) in Definition SQL Statements in the manual HADB SQL Reference.

A user (the HADB user with the authorization identifier that was used for the current connection to the HADB server) can delete only those indexes owned by that user. A user cannot delete indexes owned by other HADB users.

Also, you cannot delete the following indexes by using the DROP INDEX statement. If you want to delete such an index, use the DROP TABLE statement to delete the entire base table.

Important

Before you delete indexes, check whether you need to re-execute the command for the base table for which the target indexes (B-tree indexes or text indexes) are defined (whether the base table is non-updatable). For details about the check method, see (1) Checking whether a base table is non-updatable in 10.9.2 Checking the status and usage of a base table.

If re-execution of the command is necessary

Re-execute the command. Then, delete the indexes.

If you deleted indexes when command re-execution was necessary (when the base table was non-updatable)

Temporary work files created by the interrupted command might remain. To delete the temporary work files, you must release all base tables from the non-updatable status. For details about deleting temporary work files, see (2) When there are unneeded temporary work files on the disk in 15.2.5 Steps to take in the event of a shortage of disk space for storing temporary work files during command execution.