DESCRIBE INDEX

Shows the definition of a specified index as an executable CQL statement.

For Solr indexes, use DESCRIBE SEARCH INDEX.

To get all indexes for a table, use DESCRIBE TABLE. The output includes the table definition and all related index definitions.

Synopsis

DESCRIBE INDEX <keyspace_name>.<index_name>
keyspace_name

Name of the keyspace

index_name

Name of the index. If an index name was not specified when the index was created, the default name is the column name, underscore, followed by idx.

Examples

Verify that an index was created
  1. Create an index:

    CREATE INDEX nationality_idx ON cycling.cyclist_alt_stats (nationality);
  2. Show the definition of the index:

    DESC INDEX cycling.nationality_idx

    If the index exists, the result is the index definition as an executable CQL statement. It should be similar to the statement used to create the index.

    CREATE INDEX nationality_idx ON cycling.cyclist_alt_stats (nationality);
Describe 2i index
DESCRIBE INDEX cycling.blist_keys_idx;
CREATE INDEX blist_keys_idx ON cycling.birthday_list (keys(blist));
Describe SASI index
DESCRIBE INDEX cycling.cyclist_name_sasi_idx;
CREATE CUSTOM INDEX cyclist_name_sasi_idx ON cycling.country_flag (cyclist_name) USING 'org.apache.cassandra.index.sasi.SASIIndex';

Was this helpful?

Give Feedback

How can we improve the documentation?

© Copyright IBM Corporation 2026 | Privacy policy | Terms of use |  Manage Privacy Choices

Apache, Apache Cassandra, Cassandra, Apache Tomcat, Tomcat, Apache Lucene, Apache Solr, Apache Hadoop, Hadoop, Apache Pulsar, Pulsar, Apache Spark, Spark, Apache TinkerPop, TinkerPop, Apache Kafka and Kafka are either registered trademarks or trademarks of the Apache Software Foundation or its subsidiaries in Canada, the United States and/or other countries. Kubernetes is the registered trademark of the Linux Foundation.

General Inquiries: Contact IBM