今天例举2种常见的Mysql InnoDB下的行锁 现有表dr_test(id pk, name) 数据是 1 zhangsan2 lisi3 wangwu 例子1 事务1 update dr_test set name='zhaoliu' where id=1 事务2 update dr_test set name='zhaoliu1' where id=1 因为事务1对pk id =1的数据行加了行锁,事务2会阻塞 例子2 事务1 delete from dr_test where id=1