I was shocked to see this name...
Isn't SQL expected to quickly query and obtain results? How can this concept be implemented.
I asked a buddy, who thought it was a man query: multiple queries at the same time.
So Google came up with the following results:
Slow query actually corresponds to the MySQL slow query log system, which is used to record slow SQL statements.
How can we determine that execution is slow? When you show variables like '% quer %' in MySQL, you can see the long_query_time attribute, which corresponds to the set comparison time.
When you see the long_query_time attribute, you can also see that the log_slow_queries status is OFF, which indicates that slow query is not enabled.
How to enable it?
1. in Linux
Find the mysql configuration file my. ini and add the slow query configuration statement below mysqld.
Log_slow_queries =/var/lib/mysql/mysql-slow.log.
Long_query_time = 10
2. Windows
Find the mysql configuration file my. ini and add the slow query configuration statement below mysqld.
Log_slow_queries = C:/mysql/mysql-slow.log
Long_query_time = 10
10 is the second, and the configuration must be restarted.