Secondary Indexes

6 min to complete

Secondary indexes (also called global secondary indexes) are indexes created on columns that are not part of the partition key or not entirely part of it. Each secondary index indexes one specific column.) They are created for one main purpose: to allow efficient querying by a column that is not a key. CQL tables have strict schemas that define which columns form a primary key, and fundamentally you should use these keys to extract data from the database. But, in practice, you may want to occasionally query by a different, non primary key column, or several of them. How do you achieve that? One of the ways is to create a secondary index on that column.

 

Transcript
fa-angle-up