MySQL 事务隔离级别为READ-COMMITED 的数据库中存在如下一张表mysql> show create table t1\G;
*************************** 1. row ***************************
Table: t1
Create Table: CREATE TABLE `t1` (
`id` int NOT NULL,
`testkey` int DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
Mysql>select * from t1;
+----+---------+
| id | testkey |
+----+---------+
| 1 | 1 |
| 2 | 2 |
| 3 | 4 |
| 5 | 5 |
| 8 | 8 |
该SQL 语句select * from t1 where testkey =6 for update 加锁的情况是()【单选】?