Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is MySQL index_length in bytes?

Tags:

indexing

mysql

The MySQL documentation defines index_length as "The length of the index file" but doesn't specify the unit. Is it bytes?

http://dev.mysql.com/doc/refman/5.1/en/show-table-status.html

like image 645
Teflon Ted Avatar asked Oct 01 '10 18:10

Teflon Ted


People also ask

What is Index_length?

INDEX_LENGTH. For MyISAM , INDEX_LENGTH is the length of the index file, in bytes. For InnoDB , INDEX_LENGTH is the approximate amount of space allocated for non-clustered indexes, in bytes. Specifically, it is the sum of non-clustered index sizes, in pages, multiplied by the InnoDB page size.

What is the size of MySQL database?

MyISAM tables have a default limit set to 256TB for data and index files, which you can change to 65,536TB maximum. InnoDB maximum size for tables is 256TB, which corresponds to the full tablespace size.

Are MySQL indexes stored in memory?

An index does not need to be kept in memory. It acts just like a table -- it is composed of 16KB blocks that are cached into the buffer pool as needed, then bumped out when 'old' (think "least-recently-used" caching schemes).

Does MySQL have Information_schema?

INFORMATION_SCHEMA provides access to database metadata, information about the MySQL server such as the name of a database or table, the data type of a column, or access privileges. Other terms that are sometimes used for this information are data dictionary and system catalog.


1 Answers

Yes, it is bytes. The same holds true for the other lengths in show table status. They are all in bytes:

Avg_row_length
Data_length
Max_data_length
Index_length
like image 120
Ike Walker Avatar answered Oct 26 '22 17:10

Ike Walker