简体   繁体   中英

in MySql Which is More faster and efficient, Manual Sequence or Auto Increment?

Which is More faster and efficient Manual Sequence or MySql Auto Increment? And which one we should use ? And which one is good for more efficient queries.

Create MySQL AUTO_INCREMENT column

CREATE TABLE xyz
(
ID int NOT NULL AUTO_INCREMENT,
PRIMARY KEY (ID)
)

The AUTO_INCREMENT attribute can be used to generate a unique identity By default. The starting value for AUTO_INCREMENT is 1, and it will increment by 1 for each new record. for new rows

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM