CodeZLei

  博客园 :: 首页 :: 博问 :: 闪存 :: :: 联系 :: 订阅 订阅 :: 管理 ::

2018年6月27日

摘要: a.如何获取慢sql b.解决慢sql 使用 explain 分析sql语句 table:表名; type:连接的类型 -const:主键、索引; -eq_reg:主键、索引的范围查找; -ref:连接的查找(join) -range:索引的范围查找; -index:索引的扫描; -all:全表扫描 阅读全文
posted @ 2018-06-27 10:16 CodeZLei 阅读(99) 评论(0) 推荐(0) 编辑

摘要: 一.查看表的索引 show index/keys from tblname; 查询结果介绍: Table 表的名称。 Non_unique 如果索引不能包括重复词,则为0。如果可以,则为1。 Key_name 索引的名称。 Seq_in_index 索引中的列序列号,从1开始。 Column_nam 阅读全文
posted @ 2018-06-27 10:00 CodeZLei 阅读(123) 评论(0) 推荐(0) 编辑

摘要: https://blog.csdn.net/lisuyibmd/article/details/53004848https://blog.csdn.net/alexdamiao/article/details/51934917https://blog.csdn.net/qq_22335577/art 阅读全文
posted @ 2018-06-27 09:50 CodeZLei 阅读(306) 评论(0) 推荐(0) 编辑

摘要: https://www.cnblogs.com/luyucheng/p/6306512.htmlhttps://www.cnblogs.com/wcwen1990/p/6655416.htmlhttps://www.cnblogs.com/wangdake-qq/p/7358322.html 阅读全文
posted @ 2018-06-27 09:47 CodeZLei 阅读(118) 评论(0) 推荐(0) 编辑