索引的

mysql> show indexes from recordsInRangeTest;
+--------------------+------------+--------------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+
| Table | Non_unique | Key_name | Seq_in_index | Column_name | Collation | Cardinality | Sub_part | Packed | Null | Index_type | Comment | Index_comment |
+--------------------+------------+--------------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+
| recordsInRangeTest | | PRIMARY | | id | A | | NULL | NULL | | BTREE | | |
| recordsInRangeTest | | idx_name | | name | A | | NULL | NULL | YES | BTREE | | |
| recordsInRangeTest | | idx_age | | age | A | | NULL | NULL | YES | BTREE | | |
| recordsInRangeTest | | idx_age_name | | name | A | | NULL | NULL | YES | BTREE | | |
| recordsInRangeTest | | idx_age_name | | age | A | | NULL | NULL | YES | BTREE | | |
+--------------------+------------+--------------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+
rows in set (0.00 sec)

select * from innodb_index_stats where table_name='recordsInRangeTest';

+---------------+--------------------+--------------+---------------------+--------------+------------+-------------+-----------------------------------+
| database_name | table_name | index_name | last_update | stat_name | stat_value | sample_size | stat_description |
+---------------+--------------------+--------------+---------------------+--------------+------------+-------------+-----------------------------------+
| test | recordsInRangeTest | PRIMARY | 2018-07-17 05:02:50 | n_diff_pfx01 | 24290 | 20 | id |
| test | recordsInRangeTest | PRIMARY | 2018-07-17 05:02:50 | n_leaf_pages | 55 | NULL | Number of leaf pages in the index |
| test | recordsInRangeTest | PRIMARY | 2018-07-17 05:02:50 | size | 97 | NULL | Number of pages in the index |
| test | recordsInRangeTest | idx_age | 2018-07-17 05:02:50 | n_diff_pfx01 | 6 | 29 | age |
| test | recordsInRangeTest | idx_age | 2018-07-17 05:02:50 | n_diff_pfx02 | 24576 | 29 | age,id |
| test | recordsInRangeTest | idx_age | 2018-07-17 05:02:50 | n_leaf_pages | 29 | NULL | Number of leaf pages in the index |
| test | recordsInRangeTest | idx_age | 2018-07-17 05:02:50 | size | 30 | NULL | Number of pages in the index |
| test | recordsInRangeTest | idx_age_name | 2018-07-17 05:02:50 | n_diff_pfx01 | 6 | 29 | name |
| test | recordsInRangeTest | idx_age_name | 2018-07-17 05:02:50 | n_diff_pfx02 | 11 | 29 | name,age |
| test | recordsInRangeTest | idx_age_name | 2018-07-17 05:02:50 | n_diff_pfx03 | 24576 | 29 | name,age,id |
| test | recordsInRangeTest | idx_age_name | 2018-07-17 05:02:50 | n_leaf_pages | 29 | NULL | Number of leaf pages in the index |
| test | recordsInRangeTest | idx_age_name | 2018-07-17 05:02:50 | size | 30 | NULL | Number of pages in the index |
| test | recordsInRangeTest | idx_name | 2018-07-17 05:02:50 | n_diff_pfx01 | 6 | 24 | name |
| test | recordsInRangeTest | idx_name | 2018-07-17 05:02:50 | n_diff_pfx02 | 24576 | 24 | name,id |
| test | recordsInRangeTest | idx_name | 2018-07-17 05:02:50 | n_leaf_pages | 24 | NULL | Number of leaf pages in the index |
| test | recordsInRangeTest | idx_name | 2018-07-17 05:02:50 | size | 25 | NULL | Number of pages in the index |
+---------------+--------------------+--------------+---------------------+--------------+------------+-------------+-----------------------------------+

表本身的

+--------------------+--------+---------+------------+-------+----------------+-------------+-----------------+--------------+-----------+----------------+---------------------+-------------+------------+-------------------+----------+----------------+---------+
| Name | Engine | Version | Row_format | Rows | Avg_row_length | Data_length | Max_data_length | Index_length | Data_free | Auto_increment | Create_time | Update_time | Check_time | Collation | Checksum | Create_options | Comment |
+--------------------+--------+---------+------------+-------+----------------+-------------+-----------------+--------------+-----------+----------------+---------------------+-------------+------------+-------------------+----------+----------------+---------+
| recordsInRangeTest | InnoDB | | Compact | | | | | | | | -- :: | NULL | NULL | latin1_swedish_ci | NULL | | |
+--------------------+--------+---------+------------+-------+----------------+-------------+-----------------+--------------+-----------+----------------+---------------------+-------------+------------+-------------------+----------+----------------+---------+

mysql表的核心元数据的更多相关文章

  1. mysql:表注释和字段注释

    mysql:表注释和字段注释 1 创建表的时候写注释 create table test1 ( field_name int comment '字段的注释' )comment='表的注释'; 2 修改 ...

  2. [转载]github在线更改mysql表结构工具gh-ost

    GitHub正式宣布以开源的方式发布gh-ost:GitHub的MySQL无触发器在线更改表定义工具! gh-ost是GitHub最近几个月开发出来的,目的是解决一个经常碰到的问题:不断变化的产品需求 ...

  3. 利用Flume将MySQL表数据准实时抽取到HDFS

    转自:http://blog.csdn.net/wzy0623/article/details/73650053 一.为什么要用到Flume 在以前搭建HAWQ数据仓库实验环境时,我使用Sqoop抽取 ...

  4. python 多线程删除MySQL表

    一.需求分析 在<python 统计MySQL表信息>这篇博客中,链接如下: https://www.cnblogs.com/xiao987334176/p/9901692.html 已经 ...

  5. MySQL表的碎片整理和空间回收小结

    MySQL表碎片化(Table Fragmentation)的原因 关于MySQL中表碎片化(Table Fragmentation)产生的原因,简单总结一下,MySQL Engine不同,碎片化的原 ...

  6. MySQL表的四种分区类型

    MySQL表的四种分区类型 一.什么是表分区 通俗地讲表分区是将一大表,根据条件分割成若干个小表.mysql5.1开始支持数据表分区了. 如:某用户表的记录超过了600万条,那么就可以根据入库日期将表 ...

  7. MySQL表名和数据库关键字相同解决办法

    今天改他们的代码的时候,遇到了MySQL表名和数据库关键字的问题. 由于表名是关键字,导致增删改查都报错. Hibernate: select leave0_.id as id22_, leave0_ ...

  8. MySQL 表分区详解MyiSam引擎和InnoDb 区别(实测)

    一.什么是表分区通俗地讲表分区是将一大表,根据条件分割成若干个小表.mysql5.1开始支持数据表分区了.如:某用户表的记录超过了1000万条,那么就可以根据入库日期将表分区,也可以根据所在地将表分区 ...

  9. 清除mysql表中数据

    delete from 表名; truncate table 表名; 不带where参数的delete语句可以删除mysql表中所有内容,使用truncate table也可以清空mysql表中所有内 ...

随机推荐

  1. SSH 与 SSL

    关于 ssh 有人已经总结得非常好了,这里推荐大家看下 阮一峰 写的 ssh原理与应用 写得简单易懂,非常赞. 关于 ssl  这里有一篇博文写得也不错,ssl协议详解 好了,那 ssh 和 ssl ...

  2. 安卓渗透测试工具Drozer学习笔记

    下载,并安装. pip安装即可,安装完成后可能会出现缺少twisted依赖库的问题 ➜ vul git:(master) ✗ drozer console connect drozer Server ...

  3. JavaWeb之session应用

    session和cookie都是用来存储信息的,区别是session是在服务器端存储信息,而cookie则是在浏览器端存储信息. 通常服务器端存储session,服务器端存储和获取session,一般 ...

  4. mongodb、parse-server、parse-dashboard 的启动命令

    1.mongodb启动: 1$ C:\MongoDB\Server\bin>mongod --logpath d:\mongodb\logs\log.log $ C:\MongoDB\Serve ...

  5. mybaitis动态sql利用bind标签代替%拼接完成模糊查询

    Oracle中使用bind的写法 <select id="selectUser" resultType="user" parameterType=&quo ...

  6. IOS开发数据存储篇—IOS中的几种数据存储方式

    IOS开发数据存储篇—IOS中的几种数据存储方式 发表于2016/4/5 21:02:09  421人阅读 分类: 数据存储 在项目开发当中,我们经常会对一些数据进行本地缓存处理.离线缓存的数据一般都 ...

  7. 使用单例模式来打造ActivityManager类

    单例(Singleton)模式 定义 单例模式是一种对象创建型模式,使用单例模式,可以保证为一个类只生成唯一的实例对象.也就是说,在整个程序空间中,该类只存在一个实例对象. GoF对单例模式的定义是: ...

  8. Redis笔记 -- 在 Centos7.4单机中部署Redis集群(二)

    0x00--背景和目的 在单台PC服务器上部署Redis集群,通过不同的TCP端口启动多实例,模拟多台独立PC组成集群. 0x01--环境描述: Centos版本:CentOS Linux relea ...

  9. JavaScript基础部分经典案例

    再复杂的程序都是由一个个简单的部分组成. 001案例 - 交换两个变量的值 方法01 - 使用临时变量 var n1 = 5; var n2 = 6; // 创建一个临时中介变量 tmp var tm ...

  10. BZOJ2037: [Sdoi2008]Sue的小球(区间DP)

    Time Limit: 10 Sec  Memory Limit: 64 MBSubmit: 869  Solved: 483[Submit][Status][Discuss] Description ...