未验证 提交 394a5ede 编写于 作者: S SnailClimb 提交者: GitHub

fix:少写了一个字

上级 c3ed2d73
......@@ -60,7 +60,7 @@ MySQL中的索引可以以一定顺序引用多列,这种索引叫作联合索
```
select * from user where name=xx and city=xx ; //可以命中索引
select * from user where name=xx ; // 可以命中索引
select * from user where city=xx; // 法命中索引
select * from user where city=xx; // 法命中索引
```
这里需要注意的是,查询的时候如果两个条件都用上了,但是顺序不同,如 `city= xx and name =xx`,那么现在的查询引擎会自动优化为匹配联合索引的顺序,这样是能够命中索引的.
......@@ -109,4 +109,4 @@ ALTER TABLE `table_name` ADD INDEX index_name ( `column1`, `column2`, `column3`
- 《Java工程师修炼之道》
- 《MySQL高性能书籍_第3版》
- https://juejin.im/post/5b55b842f265da0f9e589e79
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册