mirror of
https://github.com/MariaDB/server.git
synced 2025-01-20 22:12:30 +01:00
850fed3e2a
mysql-test/r/innodb.result: Result change. mysql-test/suite/rpl/r/rpl_binlog_grant.result: Result change. mysql-test/suite/rpl/r/rpl_extraColmaster_innodb.result: Result change. mysql-test/suite/rpl/r/rpl_extraColmaster_myisam.result: Result change. mysql-test/suite/rpl/t/disabled.def: Enabling some tests. mysql-test/suite/rpl/t/rpl_binlog_grant.test: Adding missing master-slave.inc, causing previous tests to pollute the binary log. mysql-test/suite/rpl_ndb/t/disabled.def: Enabling some tests.
44 lines
1 KiB
Text
44 lines
1 KiB
Text
source include/master-slave.inc;
|
|
-- source include/have_innodb.inc
|
|
-- source include/not_embedded.inc
|
|
-- source include/have_binlog_format_mixed_or_statement.inc
|
|
|
|
let $VERSION=`select version()`;
|
|
|
|
# Bug #21975: grant/revoke statements in transaction
|
|
# used to disappear from binlog upon rallback.
|
|
# Now GRANT/REVOKE do implicitly commit
|
|
# transaction
|
|
|
|
--disable_warnings
|
|
drop database if exists d1;
|
|
--enable_warnings
|
|
create database d1;
|
|
use d1;
|
|
create table t (s1 int) engine=innodb;
|
|
set @@autocommit=0;
|
|
start transaction;
|
|
insert into t values (1);
|
|
grant select on t to x@y;
|
|
#
|
|
# There is no active transaction here
|
|
#
|
|
rollback;
|
|
show grants for x@y;
|
|
--replace_result $VERSION VERSION
|
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\//
|
|
show binlog events;
|
|
start transaction;
|
|
insert into t values (2);
|
|
revoke select on t from x@y;
|
|
#
|
|
# There is no active transaction here
|
|
#
|
|
commit;
|
|
select * from t;
|
|
show grants for x@y;
|
|
--replace_result $VERSION VERSION
|
|
--replace_regex /\/\* xid=.* \*\//\/* XID *\//
|
|
show binlog events;
|
|
drop user x@y;
|
|
drop database d1;
|