Shilpa
Published in : 2022-03-03
I am running a stored procedure that is returning more than 7000 user's data fetching from 12 tables including left joins and inner joins.
Sometimes It fails and throws the below error. Sorry, I can't publish the query for that due to confidentiality.
Lost connection to MySQL server during query
My MySQL version is 8.0.24 & My workbench is failing while executing the store procedure.
call fetchUsersInfor();
What should I do to fix it? is it an issue on the database server or workbench?
Join our community and get the chance to solve your code issues & share your opinion with us
Sign up Now
Rakshit Date : 2022-03-05
Best answers
34
Best answers
34
I think it is MySQL workbench's issue. Because of multiple request, it may block the ongoing query and stop the process, so your system CPU usage can be stay under control.
For windows:
Latest version of MySQL workbench (v8+) gives option to update such timeouts.
Go to Edit > Preference > click Sql editor > find for DBMS connection read time out: 600 (In seconds)
You need to update this seconds to 1200 or 1500 as per your choice and usage/work behavior of MySQL .
For Mac:
Follow below option,
Preferences > SQL Editor > Go to MySQL Session > set connection read timeout interval
Set it to 0. It will work!