# Schema Design Recommendations (Continues...)

+ Suitable for newly added tables on TiDB databases or migrated tables compatible with the following modifications; it is necessary to pay special attention to whether the original business use requires monotonic continuity of primary keys
+ Creating a clustered table when building a table
+ Primary keys use columns with strong randomness, or use self-generated IDs to create primary keys using the AUTO_RANDOM attribute instead of AUTO_INCREMENT
+ Select the data type of the column exactly. Can use int or date type columns, avoid using string types
+ Avoid creating invalid indexes

```  
CREATE TABLE cluster_order (
  id bigint (20) unsigned AUTO_RANDOM NOT NULL,
  code varchar (30) NOT NULL,
  order_no varchar (200) NOT NULL DEFAULT “,
  status int (4) NOT NULL,
  cancle_flag int (4) DEFAULT NULL,
  create_user varchar (50) DEFAULT NULL,
  update_user varchar (50) DEFAULT NULL,
  create_time datetime DEFAULT NULL,
  update_time datetime DEFAULT NULL,
  PRIMARY KEY (id) CLUTERED
) engine=InnoDB;
```
-------------------------------------------------------------
[no notes]