Executing long-time sql like
UPDATE ACC SET A = 'EE' WHERE A IS NULL
then I found I made a mistake, so I kill my client. When I restarted client and executed another sql, like
UDPATE ACC SET A = 'EE' WHERE ID = 1888
but I got error:
ERROR 1205 (HY000): Lock wait timeout exceeded; try restarting transaction.
I searched this error and found it was caused by uncommitted transaction holding locks. My question is:
- Can close client connection stop sql execution?
- If quesion 1's answer is NO, when sql query finished but client disconnected, will MySQL commit the result?