Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 5
Server version: 5.7.12 MySQL Community Server (GPL)

Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> show variables like '%optimizer_trace%';
+------------------------------+----------------------------------------------------------------------------+
| Variable_name                | Value                                                                      |
+------------------------------+----------------------------------------------------------------------------+
| optimizer_trace              | enabled=off,one_line=off                                                   |
| optimizer_trace_features     | greedy_search=on,range_optimizer=on,dynamic_range=on,repeated_subselect=on |
| optimizer_trace_limit        | 1                                                                          |
| optimizer_trace_max_mem_size | 16384                                                                      |
| optimizer_trace_offset       | -1                                                                         |
+------------------------------+----------------------------------------------------------------------------+
5 rows in set (0.01 sec)

mysql> set optimizer_trace='enabled=on',end_markers_in_json=on;
Query OK, 0 rows affected (1.99 sec)

mysql> select * from fire.test;
+------+
| a    |
+------+
|   20 |
+------+
1 row in set (0.00 sec)

mysql> select * from information_schema.optimizer_trace\G
*************************** 1. row ***************************
                            QUERY: select * from fire.test
                            TRACE: {
  "steps": [
    {
      "join_preparation": {
        "select#": 1,
        "steps": [
          {
            "expanded_query": "/* select#1 */ select `fire`.`test`.`a` AS `a` from `fire`.`test`"
          }
        ] /* steps */
      } /* join_preparation */
    },
    {
      "join_optimization": {
        "select#": 1,
        "steps": [
          {
            "table_dependencies": [
              {
                "table": "`fire`.`test`",
                "row_may_be_null": false,
                "map_bit": 0,
                "depends_on_map_bits": [
                ] /* depends_on_map_bits */
              }
            ] /* table_dependencies */
          },
          {
            "rows_estimation": [
              {
                "table": "`fire`.`test`",
                "table_scan": {
                  "rows": 1,
                  "cost": 1
                } /* table_scan */
              }
            ] /* rows_estimation */
          },
          {
            "considered_execution_plans": [
              {
                "plan_prefix": [
                ] /* plan_prefix */,
                "table": "`fire`.`test`",
                "best_access_path": {
                  "considered_access_paths": [
                    {
                      "rows_to_scan": 1,
                      "access_type": "scan",
                      "resulting_rows": 1,
                      "cost": 1.2,
                      "chosen": true
                    }
                  ] /* considered_access_paths */
                } /* best_access_path */,
                "condition_filtering_pct": 100,
                "rows_for_plan": 1,
                "cost_for_plan": 1.2,
                "chosen": true
              }
            ] /* considered_execution_plans */
          },
          {
            "attaching_conditions_to_tables": {
              "original_condition": null,
              "attached_conditions_computation": [
              ] /* attached_conditions_computation */,
              "attached_conditions_summary": [
                {
                  "table": "`fire`.`test`",
                  "attached": null
                }
              ] /* attached_conditions_summary */
            } /* attaching_conditions_to_tables */
          },
          {
            "refine_plan": [
              {
                "table": "`fire`.`test`"
              }
            ] /* refine_plan */
          }
        ] /* steps */
      } /* join_optimization */
    },
    {
      "join_execution": {
        "select#": 1,
        "steps": [
        ] /* steps */
      } /* join_execution */
    }
  ] /* steps */
}
MISSING_BYTES_BEYOND_MAX_MEM_SIZE: 0
          INSUFFICIENT_PRIVILEGES: 0
1 row in set (0.00 sec)

最新文章

  1. iOS AFNetWorking 3.1 的网络解析
  2. HTC Vive开发笔记之手柄震动
  3. esxi安装全过程及基本配置
  4. 35 个免费创新的响应式 HTML5 模板
  5. MySQL基于mysqldump及lvmsnapshot备份恢复
  6. 【转】【iOS】导航栏那些事儿
  7. jquery.layout框架分割线
  8. 在32位Windows 8或Windows 7上安装Windows Phone 8 SDK
  9. 算法9-5:最大流算法的Java代码
  10. 记录Linux下安装elasticSearch时遇到的一些错误
  11. 在vim中使用zencoding/Emmet
  12. IdentityServer4实战 - JWT Issuer 详解
  13. A.01.09—模块的输出—PWM低端输出
  14. IntelliJ IDEA配置
  15. UVa 10905 - Children's Game 排序,题目没有说输入是int 难度: 0
  16. python 报错RuntimeError: dictionary changed size during iteration
  17. js高级-作用域链
  18. uwsgi+nginx+django生产环境部署
  19. docker(二)不管怎么样,先跑起来。运行一个samba,运行一个hello world。
  20. Spring工作原理与单例

热门文章

  1. 算法与数据结构3.3 calculator
  2. ZooKeeper server &&client
  3. Scrum 冲刺博客,项目总结
  4. 第五部分shell项目一监控脚本
  5. Android Camera多屏幕适配解决预览照片拉伸
  6. Codeforces VK Cup 2015 A.And Yet Another Bracket Sequence(后缀数组+平衡树+字符串)
  7. BZOJ1509 & 洛谷4408:[NOI2003]逃学的小孩——题解
  8. [Leetcode] single number ii 找单个数
  9. BZOJ1597 土地购买 【dp + 斜率优化】
  10. 洛谷 P4556 [Vani有约会]雨天的尾巴 解题报告