当前位置:网站首页>Differences between in and exists in MySQL
Differences between in and exists in MySQL
2022-07-01 06:02:00 【It's very quiet】
MySQL Medium in The statement is to make the appearance and the inner table as hash Connect , and exists A statement is an external statement loop loop , Every time loop Loop and query the inner table . Use scenarios :
If the two tables in the query are the same size , Then use in and exists Not much difference .
If one of the two tables is smaller , One is a big watch , Then the sub query table is very useful exists, Small use of subquery table in.
not in and not exists: If the query statement uses not in, Then the internal and external tables are scanned , No index is used ; and not extsts The subquery of can still use the index on the table . So no matter which watch is big , use not exists All ratio not in Be quick .
边栏推荐
- Small guide for rapid completion of mechanical arm (VI): stepping motor driver
- How to transmit and share 4GB large files remotely in real time?
- ONEFLOW source code parsing: automatic inference of operator signature
- 论文学习记录随笔 多标签之LSML
- Oracle sequence + trigger
- 不是你脑子不好用,而是因为你没有找到对的工具
- 亲爱的派盘用户,我要向您表白!
- 健康照明中应用的LED照明灯
- Retention rate of SQL required questions
- 3D打印机穿线:5种简单的解决方案
猜你喜欢

TIDB数据库特性总结

How to transmit and share 4GB large files remotely in real time?

论文学习记录随笔 多标签之LIFT

Advanced drawing skills of Excel lecture 100 (1) - use Gantt chart to show the progress of the project

机械臂速成小指南(六):步进电机驱动器

It's not that you have a bad mind, but that you haven't found the right tool

skywalking集成nacos动态配置

论文学习记录随笔 多标签之GLOCAL

excel高级绘图技巧100讲(一)-用甘特图来展示项目进度情况

This is the necessary software for college students 𞓜 knowledge management
随机推荐
3D打印机穿线:5种简单的解决方案
In win10 and win11, the scroll direction of Elan touch panel is reversed, and "double finger click to open the right-click menu" and "double finger scroll" are started“
MySQL数据迁移遇到的一些错误
[note] e-commerce order data analysis practice
He struggled day and night to protect his data
解决麒麟V10上传文件乱码问题
bat操作ftp上传下载命令
excel高级绘图技巧100讲(一)-用甘特图来展示项目进度情况
2022 the 8th China International "Internet +" college student innovation and entrepreneurship competition industry proposition track is open for registration!
DHT11 温湿度传感器
Looking for high school student developers with similar interests
It's not that you have a bad mind, but that you haven't found the right tool
Talking from mlperf: how to lead the next wave of AI accelerator
2022第八届中国国际“互联网+”大学生创新创业大赛产业命题赛道开启报名!
Send you through the data cloud
4GB大文件,如何实时远程传输和共享?
穿越派 你的数据云行
穿越派·派盘 + Mountain Duck = 数据本地管理
Diagramme dynamique Excel
OpenGL es: (2) relationship between OpenGL es, EGL and glsl