在read committed隔离级别下,有两个session对数据库InnoDB表tab操作进行的时间轴,假设最初表中有且只有一行a=2的记录,并且都没有其他人在操作数据库,下面描述中正确的是session Asession Btime1begin ;time2update tab set a = 1 where a = 2 ;begin;time3select * from tab where a = 1 ;time4commit ;time5select * from tab where a = 1 ;time6begin ;time7update tab set a = 2 where a = 1 ;select * from tab where a = 1 ;time9commit ;commit ;
A.
session B前两个select语句结果相同.
B.
session B后两个select语句结果相同.
C.
session B第一个和第三个语句select结果相同.
D.
session B没有执行DML语句,因此begin和commit操作没有实际意义.