问题:当在Mysql执行一个DDL语句时候,报1205. 本来想删除一段时间的数据,语句如下: delete from pdsw.mt_monitor_result_all where create_date
问题:当在Mysql执行一个DDL语句时候,报1205.
本来想删除一段时间的数据,语句如下:
delete from pdsw.mt_monitor_result_all where create_date<'2022-10-22 00:00:00';
报错如下:1205 - Lock wait timeout exceeded; try restarting transaction,主要是源数据都是屁了insert的,可能没有提交,资源被占,现在杀掉这个 锁住的进程id就OK。
1.执行 SHOW FULL PROCESSLIST,找到这个语句,最前面有这个语句的id,直接 kill ID,就可以解决。
KILL ID
执行 select * from infORMation_schema.innodb_trx,查出语句 id,和前面一样,直接kill掉就ok。
select * from information_schema.innodb_trx;
来源地址:https://blog.csdn.net/qq_52466976/article/details/127808605
--结束END--
本文标题: MySql报1205:1205 - Lock wait timeout exceeded; try restarting transaction,出现1205如何解决
本文链接: https://www.lsjlt.com/news/384130.html(转载时请注明来源链接)
有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341
下载Word文档到电脑,方便收藏和打印~
2024-05-08
2024-05-08
2024-05-08
2024-05-08
2024-05-08
2024-05-08
2024-05-08
2024-05-08
2024-05-08
2024-05-07
回答
回答
回答
回答
回答
回答
回答
回答
回答
回答
0