MySQL Workbench – Increasing Connection Time

MySQL Settings

If you do a lot of work with MySQL, you’re probably using MySQL Workbench to manage your databases and schemas. Once you start working with larger tables, it’s very likely that you’ll run into the wall of the 30 second timeout for queries.

How do you change MySQL workbench so you can run queries that take longer than 30 seconds?

Here’s the steps.

Go onto your server and launch MySQL workbench. Log in.

Choose Edit – Preferences from the top menu bar.

Go into the SQL Editor section.

The value title is:

DBMS connection read timeout interval (in seconds)

The default value is 30 seconds.

The notes for this read: The maximum amount of time the query can take to return data from the DBMS. Set 0 to skip the read timeout.

I wouldn’t advise setting zero. However, it is very common to set this number larger than 30 seconds. Maybe go for 300 (five minutes) if you tend to run long queries on purpose.

Always check your query logs to make sure your queries are running reasonably. You want to optimize your queries so they run as quickly as they can. That being said, sometimes with massive tables it’s just common sense that a query will take a while to run. This is how you handle that issue.

You’ll want to shut down SQL Workbench and restart it for this change to fully take place.

Be the first to comment

Leave a Reply

Your email address will not be published.


*


This site uses Akismet to reduce spam. Learn how your comment data is processed.