# Non-Unique Secondary Index
![`smart`](SecondaryIndexInClusteredPK_en_002_20231122.png)
![`smart`](SecondaryIndexInNonClusteredPK_en_003_20231122.png)
------------------------------------------------------------------------------
A non-unique secondary index is an index that permits the presence of duplicate key values.

On the slide, we can see that the `KEY` of the index consists of the `tableID (table ID), indexID (index ID), indexedColumnsValue (index key value)`, and an additional `PK` or `_tidb_rowid` at the end. The `tableID` identifies the table, the `indexID` identifies the specific index within the table, and the `indexedColumnsValue` identifies certain rows. 

Unlike unique indexes whose `indexedColumnsValue` can uniquely determine a row, here it can only identify certain rows due to the possibility of duplicates. However, the TiKV `KEY` requires the capability to uniquely identify a row. In this case, appends the `PK` or `_tidb_rowid` at the end is required. Because the `PK` or `_tidb_rowid` acts as a pointer to the table, it can uniquely identify a specific row. This way, the `KEY` can point to a specific row in the table.

In a non-unique secondary index, the `VALUE` for TiKV entry is always `NULL`.

Note that the slide shows three types of tables, clustered index table, non-clustered index table, and implicit primary key table. They append different unique payload to the TiKV `KEY` portion, for the TiKV `VALUE` portion, is it always `NULL`.
