Adds an index to an existing column.

Syntax

Flow chart showing the syntax of the ALTER TABLE keyword Flow chart showing the syntax of the ALTER TABLE with ADD INDEX keyword

Description

Adds new index to column of type symbol. Adding index is an atomic, non-blocking and non-waiting operation. Once complete optimiser will start using new index for SQL executions.

Example

  1. ALTER TABLE trades ALTER COLUMN instrument ADD INDEX;

:::info

For more information about indexes please refer to the INDEX section.

:::