Client hangs during long running query

[expired user #6140]'s profile image [expired user #6140] posted 12 years ago in General Permalink
I'm experiencing a situation where the client, either HeidiSQL or the command line tool, when running a long execution time query will hang. When checking the process on the server, it completes but the client fails to get the signal the work is complete. For HeidiSQL the only option is to close down the app. (Same for command line client). Interestingly, if I run the same query on the server it works normally. I haven't figured out the threashold time frame to trigger this behavior. Many times it seems random.

There must be some setting that is closing off the connection. I've checked the normal timeouts etc. with no success.

Just wondered if anyone has seen this same thing before.
ansgar's profile image ansgar posted 12 years ago Permalink
Probably you mean the server has finished the query but the client needs to retrieve the data afterwards, which can take veery long and depends on the result size. Running that on the server directly will reduce this time to a minimum, so it's surely faster there.
ansgar's profile image ansgar posted 12 years ago Permalink
Btw: HeidiSQL also tells you the network time a query took, see the SQL log after a query finished.
[expired user #6140]'s profile image [expired user #6140] posted 12 years ago Permalink
I should add that this occurs when running a stored procedure that doesn't return any data. I've seen happen for a long time and most of the time I remote desktop into the server to run long procedures. As we get more people on the system, that isn't practical so I need to find out what's happening.
ansgar's profile image ansgar posted 12 years ago Permalink
Is that happening also on other queries which take a few seconds, for example when you run
SELECT BENCHMARK(100000000, 10*10)
?

Please login to leave a reply, or register at first.