当前位置:网站首页>[MySQL] Using join buffer (Block Nested Loop) in left join due to character set in mysql
[MySQL] Using join buffer (Block Nested Loop) in left join due to character set in mysql
2022-08-10 23:12:00 【Tao Shihan】
I found that the index was not used when querying a sql today
I read it carefully many times, and I have added all the indexes that should be added, but it still doesn't work
View with explain
Why does the index fail
- Implicit conversion causes index invalidation
- With the growth of the table, the data from the where condition is too much, more than 15%, which makes the index invalid (it will cause the CBO calculation to use the index to cost more than the whole table)
- Inconsistent character sets cause the index to fail, one utf8 and one utf8mb4
My main problem here is that the character set is inconsistent and the index is invalid
Convert the character set successfully
ALTER TABLE user CONVERT TO CHARSET utf8mb4;
边栏推荐
- 3598. Binary tree traversal (Huazhong University of Science and Technology exam questions)
- 【640. 求解方程】
- VulnHub之DC靶场下载与DC靶场全系列渗透实战详细过程
- [Autumn Recruitment] [Updating ing] Hand Tear Code Series
- pytorch tear CNN
- 确诊了!是Druid1.1.20的锅,查询无法映射LocalDateTime类型(带源码解析及解决方案)
- leetcode:355. 设计推特
- 数学建模准备知识
- "DevOps Night Talk" - Pilot - Introduction to CNCF Open Source DevOps Project DevStream - feat. PMC member Hu Tao
- Qualcomm Platform Development Series Explanation (Application) Introduction to QCMAP Application Framework
猜你喜欢
随机推荐
浅谈cors
【秋招】【更新中ing】手撕代码系列
基于交流潮流的电力系统多元件N-k故障模型研究(Matlab代码实现)【电力系统故障】
实例053:按位异或
Mysql之部分表主从搭建及新增表
实例052:按位或
[Autumn Recruitment] [Updating ing] Hand Tear Code Series
Introduction to the use of counter instructions in Rockwell AB PLC RSLogix5000
虎牙自动发弹幕换牌子
gcc492 compile `.rodata‘ can not be used when making a PIE object; recompile with -fPIE
Qualcomm Platform Development Series Explanation (Application) Introduction to QCMAP Application Framework
STL-deque
【Linux】宝塔面板设置MySQL慢查询日志,未走索引日志
virtual address space
罗克韦尔AB PLC RSLogix5000中计数器指令使用方法介绍
【uniapp】uniapp微信小程序开发:启动微信开发者工具提示no such file or directory错误
XSLeaks 侧信道攻击 (unfinished)
文件IO-缓冲区
Addition of linked lists (2)
RecyclerView滑动监听








