Welcome to Server Circle. It's a friendly site and all levels of experience are welcome. Be aware that we use cookies for your login.
Server Circle - Ask questions about Servers and get answers from experts.
Beta (0.87 sec)
Optimise MYSQL queries

There's a few HOWTOs and FAQs out there but I'm looking for a guide that will work for optimising MYSQL queries on Linux for sure. Thanks.
Asked by:
TomPating
1355 points
 Report Abuse
 Share Page - Category: CentOS Linux - Tags: Optimise MYSQL queries
 Enter your response
Please use Pastie.org to paste lengthy code or to fix formatting issues with code
  • Responses in reverse (2)

Best Answer

There is no definitive way to do this. Many factors need to be taken into consideration when designing the database structure, when plans change things can get messy.

Primary keys and correct indexes are critical, but these are no good if you're going to search a table that results in these not being used and it containing thousands of rows.

Probably the most useful function in MySQL is explain, this will show you what the sql query is doing and you should be able to play about with different versions of the query to get the optimal performance for your situation.

MySQL now has profiling (http://dev.mysql.com/tech ...) this should help show up bottlenecks in your existing setup with an aim to increasing performance.


Response by:
_SteveWilson ...
4290 points
I think I understand. Ta.

Response by:
TomPating
1355 points


  • Related Questions
About Us : Contact Us : Etiquette : Terms : CDN Failover : ShorterURL : CDN Fallback : © 2013 Server Circle