Storage Layout Tips In InnoDB, having a long PRIMARY KEY (either a single column with a lengthy value, or several columns that form a long composite value) wastes a lot of disk space. The primary key value for each row must be stored with each corresponding secondary index record. (See Section 13.6.10, “InnoDB Table and Index Structures”.) Create an AUTO_INCREMENT column as the primary key if your primary key is long. Use the VARCHAR data type instead of CHAR to store variable-length strings or for columns with many NULL values. A CHAR(N) column always takes N characters to store data, even if the string is shorter or its value is NULL. Smaller tables fit better in the buffer pool and reduce disk I/O. When using COMPACT row format (the default InnoDB format in MySQL 5.5) and variable-length character sets, such as utf8 or sjis, CHAR(N) columns occupy a variable amount of space, at least N bytes. 有2个疑问:
1, each corresponding secondary index record 我知道大概的意思,但是翻译成中文是啥意思?我说不上来。2,row format与the default InnoDB format in MySQL 5.5有何关系,5.5的default innodb format是啥模式?
1, each corresponding secondary index record 我知道大概的意思,但是翻译成中文是啥意思?我说不上来。2,row format与the default InnoDB format in MySQL 5.5有何关系,5.5的default innodb format是啥模式?
解决方案 »
- MySQL 如何给用户账号开放 修改自己密码的权限?
- xampp 和 mysql冲突
- bat问题
- postgresql 函数如何返回多个表数据???
- 小妹请教前辈们如何查找上周末的记录问题!
- MySQL建表时能否使用“自增长“
- 请问谁有用过ASP 连接SQL(个人版)的
- mysql WHERE查询机制
- 怎么查询积分大于6的所有用户信息啊
- You have an error in your SQL syntax; check the manual that corresponds to your
- innodb plugin后的问题
- 测试mysql.Access denied for user 'ODBC'@'localhost' (using password: NO) 怎样解决?
2 mysql 5.5中默认innodb的行格式 就是 紧凑行格式
fixed
compressed
dynamic等把