Mysql中Cardinality
来源:互联网 发布:丝路英雄转生数据 编辑:程序博客网 时间:2024/06/07 09:38
查看官方文档的解释:
An estimate of the number of unique values in the index. This is updated by running ANALYZE TABLE or myisamchk -a. Cardinality is counted based on statistics stored as integers, so the value is not necessarily exact even for small tables. The higher the cardinality, the greater the chance that MySQL uses the index when doing joins.
所以这个Cardinality会有如下的含义:
1. 列值代表的是此列中存储的唯一值的个数(如果此列为primary key 则值为记录的行数)
2. 列值只是个估计值,并不准确。
3. 列值不会自动更新,需要通过Analyze table来更新一张表或者mysqlcheck -Aa来进行更新整个数据库。
4. 列值的大小影响Join时是否选用这个Index的判断。
5. 创建Index时,MyISAM的表Cardinality的值为null,InnoDB的表Cardinality的值大概为行数。
6. MyISAM与InnoDB对于Cardinality的计算方式不同。
这篇文章介绍很详细:
http://www.mysqlperformanceblog.com/2008/09/03/analyze-myisam-vs-innodb/
- MySQL中Cardinality介绍
- Mysql中Cardinality
- MySQl中关于Cardinality的理解
- MySQL中Cardinality值的介绍
- MySQL中Cardinality值的介绍
- mysql cardinality 索引选择
- InnoDB中Cardinality介绍
- show index 之Cardinality (mysql)
- MySQL CARDINALITY确认索引选择性
- CARDINALITY
- CARDINALITY
- Cardinality
- Cardinality
- Cardinality
- Cardinality
- mysql引擎InnoDB索引中的cardinality关键字
- Mysql索引Cardinality属性实例探查
- oracle中执行计划中的cardinality
- linux -- 启动分析及耗时分析
- 树莓派3BWIFI配置(ssh方式配置)
- springboot thymeleaf简单整合
- 【python】 os.path模块介绍
- Centos7下jdk安装
- Mysql中Cardinality
- Retrofit、RxJava和OkHttp使用
- "Apache Shiro介绍"阅读与吸收
- javascript来实现无缝文字的滚屏
- 折半查询
- bryce1010的图像处理课程设计
- Makefile写法
- HDU2586How far away ?
- 一张图说明cdn网络