In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)05/31 Report--
This article editor for you detailed introduction of "mysql limit pagination is too slow how to solve", the content is detailed, the steps are clear, the details are handled properly, I hope this "mysql limit pagination is too slow how to solve" article can help you solve doubts, following the editor's ideas slowly in-depth, together to learn new knowledge.
1. Use the overlay index of the table to speed up the paging query. Because there is an optimization algorithm for using index lookup, and the data is on the query index, there is no need to find the relevant data address.
This will save a lot of time.
In addition, Mysql also has related index caching, which works better when concurrency is high.
Select id from product limit 866613, 20
2. Use join.
If you find the ID first, and then associate the query records, it will be much faster, because the index will quickly find a qualified ID.
SELECT * FROM product aJOIN (select id from product limit 866613, 20) b ON a.ID = b.id
3. Use the form id > =.
SELECT * FROM productWHERE ID > = (select id from product limit 866613, 1) limit 20 read here, this article "how to solve the problem of slow mysql limit pagination" has been introduced. If you want to master the knowledge points of this article, you still need to practice and use it to understand it. If you want to know more about related articles, please follow the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.