Static (fixed-length) Table features in MySQL

Source: Internet
Author: User

The static format is the default storage format of the MyISAM table. This format is used when the table does not contain variable length columns (VARCHAR, BLOB, or TEXT. Each row is stored with a fixed number of nodes.

Among the three storage formats of MyISAM, the static format is the simplest and safest (at least for crash ). Static format is also the fastest on-disk format. The easy way to quickly find rows from data files on the disk: when you search for a row based on the row number in the index, multiply the row length by the row number. Similarly, when scanning a table, it is easy to read a certain number of records with each disk.

When the MySQL server is writing data to a fixed MyISAM file, if the computer crashes, the security is clear. In this case, myisamchk can easily determine the start and end of each line, so it can usually retrieve all records except write a part of the records. Note: Based on data rows, MyISAM Table indexes can be rebuilt all the time.

General features of a static table:

· The CHAR column fills in the column width.

· Very fast.

· Easy to cache.

· Easy reconstruction after a crash, because the record is in a fixed position.

· Reorganizing is unnecessary unless you delete a large number of records and want to free up disk space for the operating system. Therefore, you can use optimize table or myisamchk-r.

· Generally, more disk space is required than a dynamic table.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.