1
drop table if exists t1,t2;
2
drop database if exists mysqltest;
3
create temporary table t1(n int not null primary key);
4
create table t2(n int);
5
insert into t2 values(3);
9
flush tables with read lock;
11
ERROR HY000: Can't execute the query because you have a conflicting read lock
14
create database mysqltest;
15
create table mysqltest.t1(n int);
16
insert into mysqltest.t1 values (23);
17
flush tables with read lock;
18
drop database mysqltest;
19
select * from mysqltest.t1;
23
create table t1 (c1 int);
25
flush tables with read lock;
26
ERROR HY000: Can't execute the given command because you have active locked tables or an active transaction
28
flush tables with read lock;
30
ERROR HY000: Can't execute the query because you have a conflicting read lock
33
ERROR HY000: Can't execute the query because you have a conflicting read lock
35
create table t2 (c1 int);
36
create table t3 (c1 int);
37
lock table t1 read, t2 read, t3 write;
38
flush tables with read lock;
39
ERROR HY000: Can't execute the given command because you have active locked tables or an active transaction
40
lock table t1 read, t2 read, t3 read;
41
flush tables with read lock;
43
drop table t1, t2, t3;
44
create table t1 (c1 int);
45
create table t2 (c1 int);
47
flush tables with read lock;
48
insert into t2 values(1);
51
select benchmark(200, (select sin(1))) > 1000;