MySQL data storage format-avoid row overflow

InnoDB is a storage engine that stores data on disk.

The query needs to read the disk data to the memory for processing, and the modification and deletion needs to write the memory data to the disk. Disk IO is very slow, so use pages (16KB) as the basic unit of memory and disk interaction.

 

Insert a piece of data, the data is included in the page, each data storage has a certain format requirements, specified by ROW_FORMAT. Such as: CREATE TABLE table name (column information) ROW_FORMAT = row format name;

row_format There are four Compactformats: Redundant, , DynamicandCompressed

 

 Regulations: each line can store up to 65535 bytes (except 64KB, BLOB, TEXT). If the size is exceeded, table creation fails.

 

 utf8 A character consists of 1 ~ 3 bytes.

 

A page can be up to 16KB and a record can be up to 64KB. There is a case where a row cannot store the next row of records, that is, a row overflow .

 

Guess you like

Origin www.cnblogs.com/tommaoxiaoqi/p/12735719.html