summaryrefslogtreecommitdiff
path: root/mysql-test/r/view_multi.result
blob: 95a8d572be4908dd56d3aee7410ee112684e7628 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
reset master;
create table t1 (i int);
create table t2 (i int);
create view v1 as select * from t1;
select get_lock("lock_bg25144", 1);
get_lock("lock_bg25144", 1)
1
insert into v1 values (get_lock("lock_bg25144", 100));;
drop view v1;;
select release_lock("lock_bg25144");
release_lock("lock_bg25144")
1
select release_lock("lock_bg25144");
release_lock("lock_bg25144")
1
select * from t1;
i
1
create view v1 as select * from t1;
select get_lock("lock_bg25144", 1);
get_lock("lock_bg25144", 1)
1
insert into v1 values (get_lock("lock_bg25144", 100));;
alter view v1 as select * from t2;;
select release_lock("lock_bg25144");
release_lock("lock_bg25144")
1
select release_lock("lock_bg25144");
release_lock("lock_bg25144")
1
select * from t1;
i
1
1
select * from t2;
i
show binlog events in 'master-bin.000001' from 107;
Log_name	Pos	Event_type	Server_id	End_log_pos	Info
master-bin.000001	#	Query	1	#	use `test`; create table t1 (i int)
master-bin.000001	#	Query	1	#	use `test`; create table t2 (i int)
master-bin.000001	#	Query	1	#	use `test`; CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select * from t1
master-bin.000001	#	Query	1	#	use `test`; insert into v1 values (get_lock("lock_bg25144", 100))
master-bin.000001	#	Query	1	#	use `test`; drop view v1
master-bin.000001	#	Query	1	#	use `test`; CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select * from t1
master-bin.000001	#	Query	1	#	use `test`; insert into v1 values (get_lock("lock_bg25144", 100))
master-bin.000001	#	Query	1	#	use `test`; ALTER ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select * from t2
drop table t1, t2;
drop view v1;