Avatar of RGuillermo
RGuillermo
Flag for United States of America asked on

MYSQL why is it sometimes too slow ?

Hello experts,
we have a small database in mysql,
its usually performs really fast
but  sometimes when requesting a very simple query
 it will take too long to respond... like 30 secs o more... and its a very simple query.
and the table is too small....
I have noticed that maybe there are other connections still open and i think not operating.
Could this be the cause and if so what tools do i have to control this ?
Regards
DatabasesMySQL Server

Avatar of undefined
Last Comment
RGuillermo

8/22/2022 - Mon
Ryan Chong

you may try to debug via the execution plan to see if there's any abnormalities?

7.4 Visual Explain Plan
https://dev.mysql.com/doc/workbench/en/wb-performance-explain.html
ASKER CERTIFIED SOLUTION
theGhost_k8

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Vitor Montalvão

I would say that when having multiple connections accessing the table at same time, you will face this poor query performance.
Do you have any index created in that table?
RGuillermo

ASKER
Thanks to all Experts, it took us a while test all posibilites
Your help has saved me hundreds of hours of internet surfing.
fblack61
theGhost_k8

It'd be better if you can post your findings for people who come surfing here.
RGuillermo

ASKER
Two findings.
1. We improved the design of our database... normalizing and eliminating reduce where possible.
2. having adequate indexes and not too many
3. when executing queries be careful with search criteria......
4. If all the above are met very likely you get a fine performance or at least acceptable.
All these come from our programmers...
Regards