# Non-Unique Secondary Index and `NON-CLUSTERED` Index Table - Example

```9
CREATE TABLE components (
  ~!@id INT PRIMARY KEY NONCLUSTERED@!~,
  name VARCHAR(20),
  role VARCHAR(20),
  startup_order INT,
  ~!@KEY startup_order_idx (startup_order)@!~
);

INSERT INTO components VALUES
  ( 100, "TiDB", "SQL Layer", 30 ),
  ( 200, "TiKV", "KV Engine", 20 ),
  ( 300, "PD", "Manager", 10 ),
  ( 400, "TiFlash", "Columnar Engine", 40 );

SELECT _tidb_rowid, id, startup_order FROM components;

+-------------+-----+---------------+
| _tidb_rowid | id  | startup_order |
+-------------+-----+---------------+
|           1 | 100 |            30 |
|           2 | 200 |            20 |
|           3 | 300 |            10 |
|           4 | 400 |            40 |
+-------------+-----+---------------+
4 rows in set (0.00 sec)
```
![`smart`](SecondaryIndexInNonClusteredPKExample_en_002_20231122.png)
------------------------------------------------------------------------------
Assume that the table `components` has an automatically assigned unique table ID, which is referred to as `t10`, the primary key index ID is `i1` and the secondary index ID is `i2`. 

The diagram on the right shows you the TiKV entries for the non-unique secondary index, the primary key index, and their underlying table.
