1
--source include/have_innodb.inc
2
--source include/have_binlog_format_mixed_or_row.inc
3
--source include/master-slave.inc
5
# Set the default connection to 'master'
9
#let $engine_type= 'myisam';
10
let $engine_type= 'innodb';
12
######## Creat Table Section #########
15
eval CREATE TABLE test.regular_tbl(id MEDIUMINT NOT NULL AUTO_INCREMENT,
16
dt TIMESTAMP, user CHAR(255), uuidf LONGBLOB,
17
fkid MEDIUMINT, filler VARCHAR(255),
18
PRIMARY KEY(id)) ENGINE=$engine_type;
20
######## Create SPs, Functions, Views and Triggers Section ##############
23
CREATE PROCEDURE test.proc_norm()
25
DECLARE ins_count INT DEFAULT 1000;
26
DECLARE del_count INT;
27
DECLARE cur_user VARCHAR(255);
28
DECLARE local_uuid VARCHAR(255);
29
DECLARE local_time TIMESTAMP;
31
SET local_time= NOW();
32
SET cur_user= CURRENT_USER();
33
SET local_uuid= UUID();
35
WHILE ins_count > 0 DO
36
INSERT INTO test.regular_tbl VALUES (NULL, NOW(), USER() , UUID(),
37
ins_count,'Going to test MBR for MySQL');
38
SET ins_count = ins_count - 1;
41
SELECT MAX(id) FROM test.regular_tbl INTO del_count;
42
WHILE del_count > 0 DO
43
DELETE FROM test.regular_tbl WHERE id = del_count;
44
SET del_count = del_count - 2;
50
############ Finish Setup Section ###################
53
############ Test Section ###################
55
CALL test.proc_norm();
57
--sync_slave_with_master
59
###### CLEAN UP SECTION ##############
62
DROP PROCEDURE test.proc_norm;
63
DROP TABLE test.regular_tbl;
65
--source include/master-slave-end.inc