Updated on 2026-11-06 GMT+08:00

ALTER INDEX

Function

ALTER INDEX can be used to rebuild or optimize an existing index.

Constraints

Currently, it can only optimize indexes of Lance foreign tables.

Syntax

1
ALTER INDEX [ IF EXISTS ] index_name ON table_name (OPTIMIZE);

Parameter Description

  • index_name: index name
  • table_name: name of the table for which an index is to be created