Usage and Application of MySQL INT,TINYINT,SMALLINT,BIGINT
MySQL INT,TINYINT,SMALLINT,BIGINT usage and application, MySQL supports all standard SQL integer types INTEGER, INT, and SMALLINT. In addition, MySQL provides TINYINT, MEDIUMINT,BIGINT as an extension of the standard SQL, which is usually used as the primary key of a table because the integer type represents an exact number. In addition, INT columns can have the AUTO_INCREMENT attribute.
1, value range
2, use
So it is usually used as the primary key id of the table
You can also use foreign keys, time, sorting, etc.
USE huthondb
CREATE TABLE items (
Iid INT AUTO_INCREMENT PRIMARY KEY
Text VARCHAR (255)
);
Note that MySQL provides an extension that allows you to specify the display width and the INT data type. The display width is enclosed in parentheses after the INT keyword, for example, INT (10) specifies an INT with a display width of five digits. The maximum is 11
Article from (www.huthon.com)