Product Documentation

SQL Reference Guide

Previous Topic

Next Topic

ALTER INDEX

Description

Alters an existing index by passing specific c-tree file attributes to change, or by renaming the index.

Syntax

ALTER INDEX [ owner_name. ] index_name [ON [ owner_name. ] table_name

{STORAGE_ATTRIBUTES 'attributes'

| RENAME TO new_index_name

};

(Support for altering an index by renaming it, RENAME TO new_index_name, was added in V11.)

Arguments

STORAGE_ATTRIBUTES 'attributes'

A quoted string specifying index attributes to modify. FairCom DB SQL recognizes the following attributes:

  • 'HUGE' -- Recreate the index file as a c-tree HUGE file.
  • 'partition=<rule>' -- Use this index with <rule> as a partition rule and create table as partitioned file. Only one index can be the partitioning index rule for a table at a time.

Examples

By default, FairCom DB SQL returns an error in response to an ALTER INDEX statement:

ISQL> alter index t1_ix ON t1 RENAME TO t1_mod_ix;

Authorization

The user executing this statement must have any of the following privileges:

  • DBA privilege.
  • Ownership of the index.
  • EXCLUSIVE file access is required for any ALTER operation.

    SQL Compliance

    Extension

    Environment

    Embedded SQL, interactive SQL, ODBC applications

    Related Statements

    CREATE INDEX, DROP INDEX

TOCIndex