Sample Header Ad - 728x90

How to stop the execution of a long running insert query?

4 votes
1 answer
6881 views
I've executed an INSERT INTO ... SELECT as a job on my MySQL instance and then I realized that number of records that is selected by the WHERE condition is more than my patience. It's already taken 12 hours and there's no sign of the job being done. My previous experience tells me that there's a big chance to corrupt the data if I just kill / stop the MySQL instance. And I know no other way to do so! Does anyone know a safe way to gracefully ask MySQL to stop whatever it is doing? And I'm using InnoDb and MySQL 5.6 on Ubuntu.
Asked by Mehran (145 rep)
Apr 16, 2014, 05:19 AM
Last activity: Apr 16, 2014, 12:12 PM