MySql执行计划ext列的部分解读

发布时间 2023-05-04 21:14:21作者: JaxYoun

https://dev.mysql.com/doc/refman/5.7/en/explain-output.html#explain-extra-information
【Using filesort】 本次查询语句中有order by,且排序依照的字段不在本次使用的索引中,不能利用索引的天然有序性,需要进行额外的排序工作。
【Using index】 使用了覆盖索引——即本次查询所需的所有信息字段,都可以从索引上取得。无需回表去主索引上取数据。 The column information is retrieved from the table using only information in the index tree without having to do an additional seek to read the actual row. This strategy can be used when the query uses only columns that are part of a single index.
【Using index condition】 使用了索引下推技术ICP。(虽然本次查询所需的数据,不能从利用到的索引上完全取得,还是需要回表去主索引获取。但在回表前,充分利用索引中的字段,根据where条件,在存储引擎层就进行过滤。在存储引擎层就提前排除了不符合查询条件的行。这样就避免了在服务层执行使用该条件过滤操作,避免了额外的开销。) Tables are read by accessing index tuples and testing them first to determine whether to read full table rows. In this way, index information is used to defer (“push down”) reading full table rows unless it is necessary. See Section 8.2.1.5, “Index Condition Pushdown Optimization”.
【Using where】 表示本次查询要进行筛选过滤。