当前位置:网站首页>MySQL single table access method
MySQL single table access method
2022-06-28 07:55:00 【star++】
summary
The so-called access method is that you want to find a pile of data , And then put sql Throw it to mysql, then mysql According to your watch ( Indexes , Data volume , Query cost ), give mysql I think the best way to execute , This is the access method .mysql Give these execution methods their own names , Namely :const,
ref,ref_or_null,range,index,all,index merge
Equivalent query ( Single field single value )( Walk a single index )
1.const Method
select * from user where id=? //id It's the primary key ( Cluster index )
select * from user where stu_id=? // Student ID is the unique index ( Secondary indexes )
1. If the query condition is Primary key or unique index , So the way to access the table is const
2. Generally speaking, it is a method to retrieve a record , be used const
3. If the primary key or unique index is multi column , So many columns must be equal , This is when const
4. If the primary key and unique index retrieve null边栏推荐
- HJ删除字符串中出现次数最少的字符
- Redis one master multi slave cluster setup
- MySQL installation and environment variable configuration
- Redis implements distributed locks
- Ice, protobuf, thrift -- Notes
- SQL master-slave replication setup
- HJ成绩排序
- Source code analysis of kubernetes' process of deleting pod
- flex布局
- MMR rearrangement (similarity is calculated by editing distance and repeatability)
猜你喜欢

Section 8: DMA of zynq

Ambari (VIII) --- ambari integrated impala document (valid for personal test)

Tencent continued to lay off staff in the second half of the year, and all business groups reduced by at least 10%. What do you think of this? Followers

SOC serial port configuration

Safety training is the greatest benefit for employees! 2022 induction safety training for new employees

asp. Net registration page

Ambari (VII) --- ambari integrated hue4.2 document (valid for personal test)

Rediscluster cluster mode capacity expansion node

异或的应用。(提取出数字中最右侧的1,面试中经常用的到)

Resizing node of rediscluster cluster cluster mode
随机推荐
8 figures | analyze Eureka's first synchronization registry
Investment transaction and settlement of the fund
Recommended system series (Lecture 5): Optimization Practice of sorting model
软件测试与质量期末复习
GPIO configuration of SOC
kubernetes集群命令行工具kubectl
Airflow2 configuration windows azure SSO details based on oauth2 protocol
Kubernetes cluster command line tool kubectl
[JS] - [DFS, BFS application] - learning notes
Is it reliable for securities companies to register and open accounts? Is it safe?
Is it reliable for flush to register and open an account? Is it safe?
asp. Net datalist to display product information and pictures
HJ删除字符串中出现次数最少的字符
flutter 实现摇一摇功能
HJ整数与IP地址间的转换
Ice - resources
Design of DSP image data stream
Conversion between HJ integer and IP address
Idea package together, using compact middle packages to solve &
HJ字符串排序