Get the App
SLTechnology News&Howtos  ›  Database  › 

A brief Analysis of the process of using using where and using index in mysql Database explain

Shulou Source: shulou.com Published: 2022-06-01 20:25:45 10月02日 Update

This paper mainly introduces a brief analysis of the use process of using where and using index in mysql database explain, and the things involved are learned from theoretical knowledge. There are many books and documents for your reference. From the perspective of practical significance, the accumulated practical experience for many years can be shared with you.

1. Look at all the indexes in the table show index from modify_passwd_log; has two primary key indexes for id and a normal index for email_id

2. Using index means that the index is used, and the data fetched can be obtained completely in the index.

Explain select email_id from modify_passwd_log where email_id=670602

3. Type is ref,where is blank: index is used, but the data queried is not in the index, go back to the table to get the data

Explain select * from modify_passwd_log where email_id=670602

4. Type is ref, and where is using where, indicating that the index is used, but where filtering is also performed.

For more information:

The difference between using index and using where in executing extra in MySQL Database

Detailed explanation of the concepts of Using where and Using index in MySQL query optimization

Tags: Index data database query process ordinary east-west two books years meaning literature more concept reality theory knowledge blank experience perspective Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Xiaomi Apple MySQL Shulou Information MariaDB