Commit 480a4852 authored by Alexey Kopytov's avatar Alexey Kopytov

Manual merge of local mysql-trunk-merge with bk-internal.

Conflicts:

Text conflict in sql/CMakeLists.txt
parents 940ad61b 2a95927f
...@@ -45,7 +45,7 @@ noinst_HEADERS = config-win.h config-netware.h lf.h my_bit.h \ ...@@ -45,7 +45,7 @@ noinst_HEADERS = config-win.h config-netware.h lf.h my_bit.h \
my_vle.h my_user.h my_atomic.h atomic/nolock.h \ my_vle.h my_user.h my_atomic.h atomic/nolock.h \
atomic/rwlock.h atomic/x86-gcc.h atomic/generic-msvc.h \ atomic/rwlock.h atomic/x86-gcc.h atomic/generic-msvc.h \
atomic/gcc_builtins.h my_libwrap.h my_stacktrace.h \ atomic/gcc_builtins.h my_libwrap.h my_stacktrace.h \
atomic/solaris.h atomic/solaris.h mysql/innodb_priv.h
EXTRA_DIST = mysql.h.pp mysql/plugin.h.pp probes_mysql.d.base \ EXTRA_DIST = mysql.h.pp mysql/plugin.h.pp probes_mysql.d.base \
CMakeLists.txt \ CMakeLists.txt \
......
...@@ -6,7 +6,9 @@ binlog.binlog_multi_engine # joro : NDB tests marked as experiment ...@@ -6,7 +6,9 @@ binlog.binlog_multi_engine # joro : NDB tests marked as experiment
funcs_1.charset_collation_1 # depends on compile-time decisions funcs_1.charset_collation_1 # depends on compile-time decisions
funcs_1.myisam_views @solaris # Bug#50595 2010-03-05 alik funcs_1.myisam_views takes longer time on 6.0 branch than 5.1 branch funcs_1.myisam_views @solaris # Bug#50595 2010-03-05 alik funcs_1.myisam_views takes longer time on 6.0 branch than 5.1 branch
main.func_math @freebsd # Bug#43020 2010-05-04 alik main.func_math fails on FreeBSD in PB2
main.gis @solaris # Bug#52208 2010-04-26 alik gis fails on some platforms (Solaris, HP-UX, Linux) main.gis @solaris # Bug#52208 2010-04-26 alik gis fails on some platforms (Solaris, HP-UX, Linux)
main.gis-rtree @freebsd # Bug#38965 2010-05-04 alik test cases gis-rtree, type_float, type_newdecimal fail in embedded server
main.information_schema # Bug#47449 2009-09-19 alik main.information_schema and innodb.innodb_information_schema fail sporadically main.information_schema # Bug#47449 2009-09-19 alik main.information_schema and innodb.innodb_information_schema fail sporadically
main.lock_multi_bug38499 # Bug#47448 2009-09-19 alik main.lock_multi_bug38499 times out sporadically main.lock_multi_bug38499 # Bug#47448 2009-09-19 alik main.lock_multi_bug38499 times out sporadically
main.lock_multi_bug38691 @solaris # Bug#47792 2009-10-02 alik main.lock_multi_bug38691 times out sporadically on Solaris 10 main.lock_multi_bug38691 @solaris # Bug#47792 2009-10-02 alik main.lock_multi_bug38691 times out sporadically on Solaris 10
...@@ -16,9 +18,9 @@ main.mysqlbinlog_row_innodb @solaris # Bug#52202 2010-03-22 alik mysqlbinlog ...@@ -16,9 +18,9 @@ main.mysqlbinlog_row_innodb @solaris # Bug#52202 2010-03-22 alik mysqlbinlog
main.mysqlbinlog_row_myisam @solaris # Bug#52202 2010-03-22 alik mysqlbinlog_row* fail in daily-trunk on Sol10 x86_64 debug_max main.mysqlbinlog_row_myisam @solaris # Bug#52202 2010-03-22 alik mysqlbinlog_row* fail in daily-trunk on Sol10 x86_64 debug_max
main.outfile_loaddata @solaris # Bug#46895 2010-01-20 alik Test "outfile_loaddata" fails (reproducible) main.outfile_loaddata @solaris # Bug#46895 2010-01-20 alik Test "outfile_loaddata" fails (reproducible)
main.plugin* @solaris # Bug#47146 Linking problem with example plugin when dtrace enabled main.plugin* @solaris # Bug#47146 Linking problem with example plugin when dtrace enabled
main.query_cache_debug @linux # Bug#52356 2010-04-10 alik query_cache_debug fails on Linux
main.signal_demo3 @solaris # Bug#47791 2010-01-20 alik Several test cases fail on Solaris with error Thread stack overrun main.signal_demo3 @solaris # Bug#47791 2010-01-20 alik Several test cases fail on Solaris with error Thread stack overrun
main.sp @solaris # Bug#47791 2010-01-20 alik Several test cases fail on Solaris with error Thread stack overrun main.sp @solaris # Bug#47791 2010-01-20 alik Several test cases fail on Solaris with error Thread stack overrun
main.type_float @freebsd # Bug#38965 2010-05-04 alik test cases gis-rtree, type_float, type_newdecimal fail in embedded server
main.wait_timeout @solaris # Bug#51244 2010-04-26 alik wait_timeout fails on OpenSolaris main.wait_timeout @solaris # Bug#51244 2010-04-26 alik wait_timeout fails on OpenSolaris
rpl.rpl_heartbeat_basic # BUG#43828 2009-10-22 luis fails sporadically rpl.rpl_heartbeat_basic # BUG#43828 2009-10-22 luis fails sporadically
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- source include/have_blackhole.inc -- source include/have_blackhole.inc
-- source include/have_log_bin.inc -- source include/have_log_bin.inc
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); CALL mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
# The server need to be started in $MYSQLTEST_VARDIR since it # The server need to be started in $MYSQLTEST_VARDIR since it
# uses ../../std_data/ # uses ../../std_data/
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
-- source include/have_log_bin.inc -- source include/have_log_bin.inc
-- source include/have_innodb.inc -- source include/have_innodb.inc
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
--disable_warnings --disable_warnings
drop table if exists t1, t2; drop table if exists t1, t2;
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
# #
######################################################################################## ########################################################################################
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
CREATE TABLE t1(a INT PRIMARY KEY, data VARCHAR(30000)) ENGINE=Innodb; CREATE TABLE t1(a INT PRIMARY KEY, data VARCHAR(30000)) ENGINE=Innodb;
CREATE TABLE t2(a INT PRIMARY KEY, data VARCHAR(30000)) ENGINE=MyIsam; CREATE TABLE t2(a INT PRIMARY KEY, data VARCHAR(30000)) ENGINE=MyIsam;
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
# column and index but without primary key. # column and index but without primary key.
############################################################## ##############################################################
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
--echo # --echo #
--echo # Setup --echo # Setup
......
...@@ -19,7 +19,7 @@ reset master; ...@@ -19,7 +19,7 @@ reset master;
connection master; connection master;
--disable_query_log --disable_query_log
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); CALL mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
--enable_query_log --enable_query_log
# MTR is not case-sensitive. # MTR is not case-sensitive.
......
...@@ -245,7 +245,7 @@ ...@@ -245,7 +245,7 @@
--echo # CONFIGURATION --echo # CONFIGURATION
--echo ######################################################################### --echo #########################################################################
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
SET @commands= 'configure'; SET @commands= 'configure';
--source extra/rpl_tests/rpl_mixing_engines.inc --source extra/rpl_tests/rpl_mixing_engines.inc
......
...@@ -4,10 +4,10 @@ ...@@ -4,10 +4,10 @@
# Let the master do lots of insertions # Let the master do lots of insertions
connection master; connection master;
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
connection slave; connection slave;
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
connection master; connection master;
create table t1(n int); create table t1(n int);
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
-- source include/have_binlog_format_statement.inc -- source include/have_binlog_format_statement.inc
-- source include/master-slave.inc -- source include/master-slave.inc
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); CALL mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
# Load some data into t1 # Load some data into t1
create table t1 (word char(20) not null); create table t1 (word char(20) not null);
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
connection master; connection master;
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
create table tm (a int auto_increment primary key) engine=myisam; create table tm (a int auto_increment primary key) engine=myisam;
create table ti (a int auto_increment primary key) engine=innodb; create table ti (a int auto_increment primary key) engine=innodb;
......
if (`select plugin_library IS NULL from information_schema.plugins where plugin_name LIKE '%federated%'`)
{
--skip federated plugin not available
}
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); CALL mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
DROP TABLE if exists t1,t2,t3,t4,t5,t6; DROP TABLE if exists t1,t2,t3,t4,t5,t6;
SET storage_engine=ARCHIVE; SET storage_engine=ARCHIVE;
CREATE TABLE t1 ( CREATE TABLE t1 (
......
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
set sql_mode=no_engine_substitution; set sql_mode=no_engine_substitution;
set storage_engine = InnoDB; set storage_engine = InnoDB;
set autocommit=1; set autocommit=1;
......
...@@ -38,22 +38,22 @@ master-bin.000001 514 Query 1 581 BEGIN ...@@ -38,22 +38,22 @@ master-bin.000001 514 Query 1 581 BEGIN
master-bin.000001 581 Query 1 788 use `mtr`; INSERT INTO test_suppressions (pattern) VALUES ( NAME_CONST('pattern',_latin1'Error in Log_event::read_log_event()' COLLATE 'latin1_swedish_ci')) master-bin.000001 581 Query 1 788 use `mtr`; INSERT INTO test_suppressions (pattern) VALUES ( NAME_CONST('pattern',_latin1'Error in Log_event::read_log_event()' COLLATE 'latin1_swedish_ci'))
master-bin.000001 788 Query 1 856 COMMIT master-bin.000001 788 Query 1 856 COMMIT
master-bin.000001 856 Query 1 923 BEGIN master-bin.000001 856 Query 1 923 BEGIN
master-bin.000001 923 Query 1 1172 use `mtr`; INSERT INTO test_suppressions (pattern) VALUES ( NAME_CONST('pattern',_latin1'Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT' COLLATE 'latin1_swedish_ci')) master-bin.000001 923 Query 1 1191 use `mtr`; INSERT INTO test_suppressions (pattern) VALUES ( NAME_CONST('pattern',_latin1'Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT' COLLATE 'latin1_swedish_ci'))
master-bin.000001 1172 Query 1 1240 COMMIT master-bin.000001 1191 Query 1 1259 COMMIT
master-bin.000001 1240 Query 1 1403 use `test`; CREATE TABLE t4 (s1 CHAR(50) CHARACTER SET latin1, master-bin.000001 1259 Query 1 1422 use `test`; CREATE TABLE t4 (s1 CHAR(50) CHARACTER SET latin1,
s2 CHAR(50) CHARACTER SET cp932, s2 CHAR(50) CHARACTER SET cp932,
d DECIMAL(10,2)) d DECIMAL(10,2))
master-bin.000001 1403 Query 1 1649 use `test`; CREATE DEFINER=`root`@`localhost` PROCEDURE `bug18293`(IN ins1 CHAR(50), master-bin.000001 1422 Query 1 1668 use `test`; CREATE DEFINER=`root`@`localhost` PROCEDURE `bug18293`(IN ins1 CHAR(50),
IN ins2 CHAR(50) CHARACTER SET cp932, IN ins2 CHAR(50) CHARACTER SET cp932,
IN ind DECIMAL(10,2)) IN ind DECIMAL(10,2))
BEGIN BEGIN
INSERT INTO t4 VALUES (ins1, ins2, ind); INSERT INTO t4 VALUES (ins1, ins2, ind);
END END
master-bin.000001 1649 Query 1 1717 BEGIN master-bin.000001 1668 Query 1 1736 BEGIN
master-bin.000001 1717 Query 1 1981 use `test`; INSERT INTO t4 VALUES ( NAME_CONST('ins1',_latin1 0x466F6F2773206120426172 COLLATE 'latin1_swedish_ci'), NAME_CONST('ins2',_cp932 0xED40ED41ED42 COLLATE 'cp932_japanese_ci'), NAME_CONST('ind',47.93)) master-bin.000001 1736 Query 1 2000 use `test`; INSERT INTO t4 VALUES ( NAME_CONST('ins1',_latin1 0x466F6F2773206120426172 COLLATE 'latin1_swedish_ci'), NAME_CONST('ins2',_cp932 0xED40ED41ED42 COLLATE 'cp932_japanese_ci'), NAME_CONST('ind',47.93))
master-bin.000001 1981 Query 1 2050 COMMIT master-bin.000001 2000 Query 1 2069 COMMIT
master-bin.000001 2050 Query 1 2136 use `test`; DROP PROCEDURE bug18293 master-bin.000001 2069 Query 1 2155 use `test`; DROP PROCEDURE bug18293
master-bin.000001 2136 Query 1 2212 use `test`; DROP TABLE t4 master-bin.000001 2155 Query 1 2231 use `test`; DROP TABLE t4
End of 5.0 tests End of 5.0 tests
SHOW BINLOG EVENTS FROM 490; SHOW BINLOG EVENTS FROM 490;
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Wrong offset or I/O error ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Wrong offset or I/O error
......
...@@ -73,3 +73,23 @@ id text ...@@ -73,3 +73,23 @@ id text
line2 line2
line3 line3
drop table t1; drop table t1;
#
# Bug#51571 load xml infile causes server crash
#
CREATE TABLE t1 (a text, b text);
LOAD XML INFILE '../../std_data/loadxml.dat' INTO TABLE t1
ROWS IDENTIFIED BY '<row>' (a,@b) SET b=concat('!',@b);
SELECT * FROM t1 ORDER BY a;
a b
1 !b1
11 !b11
111 !b111
112 !b112 & < > " ' &unknown; -- check entities
2 !b2
212 !b212
213 !b213
214 !b214
215 !b215
216 !&bb b;
3 !b3
DROP TABLE t1;
...@@ -94,7 +94,7 @@ Warnings: ...@@ -94,7 +94,7 @@ Warnings:
Warning 1265 Data truncated for column 'd' at row 1 Warning 1265 Data truncated for column 'd' at row 1
UPDATE t1 SET d=1/NULL; UPDATE t1 SET d=1/NULL;
Warnings: Warnings:
Warning 1265 Data truncated for column 'd' at row 1 Warning 1048 Column 'd' cannot be null
UPDATE t1 SET d=NULL; UPDATE t1 SET d=NULL;
Warnings: Warnings:
Warning 1048 Column 'd' cannot be null Warning 1048 Column 'd' cannot be null
......
...@@ -42,7 +42,7 @@ id ...@@ -42,7 +42,7 @@ id
SET TRANSACTION ISOLATION LEVEL READ COMMITTED; SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
BEGIN; BEGIN;
INSERT INTO t1 VALUES(9); INSERT INTO t1 VALUES(9);
ERROR HY000: Cannot execute statement: binlogging impossible since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED. ERROR HY000: Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-based logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED.
COMMIT; COMMIT;
COMMIT; COMMIT;
DROP TABLE t1; DROP TABLE t1;
...@@ -638,3 +638,22 @@ CAST(CAST('2008-07-29T10:42:51.1234567' AS DateTime) AS DECIMAL(30,7)) ...@@ -638,3 +638,22 @@ CAST(CAST('2008-07-29T10:42:51.1234567' AS DateTime) AS DECIMAL(30,7))
Warnings: Warnings:
Warning 1292 Truncated incorrect datetime value: '2008-07-29T10:42:51.1234567' Warning 1292 Truncated incorrect datetime value: '2008-07-29T10:42:51.1234567'
End of 5.1 tests End of 5.1 tests
#
# Start of 5.5 tests
#
#
# Bug#52849 datetime index not work
#
CREATE TABLE t1 (Id INT, AtTime DATETIME, KEY AtTime (AtTime));
SET NAMES CP850;
INSERT INTO t1 VALUES (1,'2010-04-12 22:30:12'), (2,'2010-04-12 22:30:12'), (3,'2010-04-12 22:30:12');
EXPLAIN EXTENDED SELECT * FROM t1 FORCE INDEX(attime) WHERE AtTime = '2010-02-22 18:40:07';
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE t1 ref AtTime AtTime 9 const 1 100.00 Using where
Warnings:
Note 1003 select `test`.`t1`.`Id` AS `Id`,`test`.`t1`.`AtTime` AS `AtTime` from `test`.`t1` FORCE INDEX (`attime`) where (`test`.`t1`.`AtTime` = '2010-02-22 18:40:07')
DROP TABLE t1;
SET NAMES latin1;
#
# End of 5.5 tests
#
...@@ -429,3 +429,34 @@ INSERT INTO t1 VALUES (1); ...@@ -429,3 +429,34 @@ INSERT INTO t1 VALUES (1);
INSERT INTO t1 VALUES (1); INSERT INTO t1 VALUES (1);
DROP TABLE t1; DROP TABLE t1;
End of 5.1 tests End of 5.1 tests
DROP TABLE IF EXISTS t1;
CREATE TABLE t1(f1 INT AUTO_INCREMENT, PRIMARY KEY(f1));
INSERT INTO t1 SET f1 = NULL ;
SET @aux = NULL ;
INSERT INTO t1 SET f1 = @aux ;
SET @aux1 = 0.123E-1;
SET @aux1 = NULL;
INSERT INTO t1 SET f1 = @aux1 ;
SELECT * FROM t1;
f1
1
2
3
DROP TABLE t1;
CREATE TABLE t1(f1 VARCHAR(257) , f2 INT, PRIMARY KEY(f2));
CREATE TRIGGER trg1 BEFORE INSERT ON t1 FOR EACH ROW SET @aux = 1;
SET @aux = 1;
SET @aux = NULL;
INSERT INTO test.t1 (f1, f2) VALUES (1, 1), (@aux, 2);
SET @aux = 'text';
SET @aux = NULL;
INSERT INTO t1(f1, f2) VALUES (1, 3), (@aux, 4);
SELECT f1, f2 FROM t1 ORDER BY f2;
f1 f2
1 1
1 2
1 3
1 4
DROP TRIGGER trg1;
DROP TABLE t1;
End of 5.5 tests
...@@ -14,12 +14,12 @@ SET BINLOG_FORMAT=STATEMENT; ...@@ -14,12 +14,12 @@ SET BINLOG_FORMAT=STATEMENT;
BEGIN; BEGIN;
SET SESSION TRANSACTION ISOLATION LEVEL READ UNCOMMITTED; SET SESSION TRANSACTION ISOLATION LEVEL READ UNCOMMITTED;
UPDATE t1 SET b = 1*a WHERE a > 1; UPDATE t1 SET b = 1*a WHERE a > 1;
ERROR HY000: Cannot execute statement: binlogging impossible since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED. ERROR HY000: Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-based logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED.
COMMIT; COMMIT;
BEGIN; BEGIN;
SET SESSION TRANSACTION ISOLATION LEVEL READ COMMITTED; SET SESSION TRANSACTION ISOLATION LEVEL READ COMMITTED;
UPDATE t1 SET b = 2*a WHERE a > 2; UPDATE t1 SET b = 2*a WHERE a > 2;
ERROR HY000: Cannot execute statement: binlogging impossible since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED. ERROR HY000: Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-based logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED.
COMMIT; COMMIT;
BEGIN; BEGIN;
SET SESSION TRANSACTION ISOLATION LEVEL REPEATABLE READ; SET SESSION TRANSACTION ISOLATION LEVEL REPEATABLE READ;
......
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
create table t1 (a int auto_increment, b int, PRIMARY KEY (a)) ENGINE=InnoDB; create table t1 (a int auto_increment, b int, PRIMARY KEY (a)) ENGINE=InnoDB;
create table t2 (a int auto_increment, b int, PRIMARY KEY (a)) ENGINE=MyISAM; create table t2 (a int auto_increment, b int, PRIMARY KEY (a)) ENGINE=MyISAM;
create table t3 (a int auto_increment, b int, PRIMARY KEY (a)) ENGINE=InnoDB; create table t3 (a int auto_increment, b int, PRIMARY KEY (a)) ENGINE=InnoDB;
......
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
CREATE TABLE t1m (m INT, n INT) ENGINE=MYISAM; CREATE TABLE t1m (m INT, n INT) ENGINE=MYISAM;
CREATE TABLE t1b (b INT, c INT) ENGINE=BLACKHOLE; CREATE TABLE t1b (b INT, c INT) ENGINE=BLACKHOLE;
CREATE TABLE t1n (e INT, f INT) ENGINE=NDB; CREATE TABLE t1n (e INT, f INT) ENGINE=NDB;
...@@ -8,14 +8,14 @@ INSERT INTO t1b VALUES (1,1), (1,2), (2,1), (2,2); ...@@ -8,14 +8,14 @@ INSERT INTO t1b VALUES (1,1), (1,2), (2,1), (2,2);
INSERT INTO t1m VALUES (1,1), (1,2), (2,1), (2,2); INSERT INTO t1m VALUES (1,1), (1,2), (2,1), (2,2);
UPDATE t1m, t1b SET m = 2, b = 3 WHERE n = c; UPDATE t1m, t1b SET m = 2, b = 3 WHERE n = c;
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statements that read from both transactional (or a temporary table of any engine type) and non-transactional tables and write to any of them are unsafe. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statements that read from both transactional (or a temporary table of any engine type) and non-transactional tables and write to any of them are unsafe.
The last event before the COMMIT is use `test`; UPDATE t1m, t1b SET m = 2, b = 3 WHERE n = c The last event before the COMMIT is use `test`; UPDATE t1m, t1b SET m = 2, b = 3 WHERE n = c
*** Please look in binlog_multi_engine.test if you have a diff here **** *** Please look in binlog_multi_engine.test if you have a diff here ****
START TRANSACTION; START TRANSACTION;
INSERT INTO t1n VALUES (1,1), (1,2), (2,1), (2,2); INSERT INTO t1n VALUES (1,1), (1,2), (2,1), (2,2);
UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f; UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f;
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statements that read from both transactional (or a temporary table of any engine type) and non-transactional tables and write to any of them are unsafe. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statements that read from both transactional (or a temporary table of any engine type) and non-transactional tables and write to any of them are unsafe.
UPDATE t1n, t1b SET e = 2, b = 3 WHERE f = c; UPDATE t1n, t1b SET e = 2, b = 3 WHERE f = c;
COMMIT; COMMIT;
TRUNCATE t1m; TRUNCATE t1m;
...@@ -55,7 +55,7 @@ The last event before the COMMIT is use `test`; INSERT INTO t1m VALUES (1,1), (1 ...@@ -55,7 +55,7 @@ The last event before the COMMIT is use `test`; INSERT INTO t1m VALUES (1,1), (1
INSERT INTO t1n VALUES (1,1), (1,2), (2,1), (2,2); INSERT INTO t1n VALUES (1,1), (1,2), (2,1), (2,2);
UPDATE t1m, t1b SET m = 2, b = 3 WHERE n = c; UPDATE t1m, t1b SET m = 2, b = 3 WHERE n = c;
UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f; UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f;
ERROR HY000: Cannot execute statement: binlogging impossible since more than one engine is involved and at least one engine is self-logging. ERROR HY000: Cannot execute statement: impossible to write to binary log since more than one engine is involved and at least one engine is self-logging.
TRUNCATE t1m; TRUNCATE t1m;
TRUNCATE t1b; TRUNCATE t1b;
TRUNCATE t1n; TRUNCATE t1n;
...@@ -82,9 +82,9 @@ INSERT INTO t1m VALUES (1,1), (1,2), (2,1), (2,2); ...@@ -82,9 +82,9 @@ INSERT INTO t1m VALUES (1,1), (1,2), (2,1), (2,2);
INSERT INTO t1b VALUES (1,1), (1,2), (2,1), (2,2); INSERT INTO t1b VALUES (1,1), (1,2), (2,1), (2,2);
INSERT INTO t1n VALUES (1,1), (1,2), (2,1), (2,2); INSERT INTO t1n VALUES (1,1), (1,2), (2,1), (2,2);
UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f; UPDATE t1m, t1n SET m = 2, e = 3 WHERE n = f;
ERROR HY000: Cannot execute statement: binlogging impossible since more than one engine is involved and at least one engine is self-logging. ERROR HY000: Cannot execute statement: impossible to write to binary log since more than one engine is involved and at least one engine is self-logging.
UPDATE t1n, t1b SET e = 2, b = 3 WHERE f = c; UPDATE t1n, t1b SET e = 2, b = 3 WHERE f = c;
ERROR HY000: Cannot execute statement: binlogging impossible since more than one engine is involved and at least one engine is self-logging. ERROR HY000: Cannot execute statement: impossible to write to binary log since more than one engine is involved and at least one engine is self-logging.
show binlog events from <binlog_start>; show binlog events from <binlog_start>;
Log_name Pos Event_type Server_id End_log_pos Info Log_name Pos Event_type Server_id End_log_pos Info
mysqld-bin.000001 # Query # # BEGIN mysqld-bin.000001 # Query # # BEGIN
......
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
drop table if exists t1, t2; drop table if exists t1, t2;
create table t1 (a int) engine=innodb; create table t1 (a int) engine=innodb;
create table t2 (a int) engine=myisam; create table t2 (a int) engine=myisam;
......
...@@ -6,7 +6,7 @@ FLUSH TABLES; ...@@ -6,7 +6,7 @@ FLUSH TABLES;
show binlog events from <binlog_start>; show binlog events from <binlog_start>;
Log_name Pos Event_type Server_id End_log_pos Info Log_name Pos Event_type Server_id End_log_pos Info
master-bin.000001 # Query # # BEGIN master-bin.000001 # Query # # BEGIN
master-bin.000001 # Query # # use `mtr`; INSERT INTO test_suppressions (pattern) VALUES ( NAME_CONST('pattern',_latin1'Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT' COLLATE 'latin1_swedish_ci')) master-bin.000001 # Query # # use `mtr`; INSERT INTO test_suppressions (pattern) VALUES ( NAME_CONST('pattern',_latin1'Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT' COLLATE 'latin1_swedish_ci'))
master-bin.000001 # Query # # COMMIT master-bin.000001 # Query # # COMMIT
master-bin.000001 # Query # # use `test`; create table t1 (a int not null auto_increment, primary key (a)) engine=myisam master-bin.000001 # Query # # use `test`; create table t1 (a int not null auto_increment, primary key (a)) engine=myisam
master-bin.000001 # Query # # BEGIN master-bin.000001 # Query # # BEGIN
...@@ -22,10 +22,10 @@ master-bin.000001 # Query # # COMMIT ...@@ -22,10 +22,10 @@ master-bin.000001 # Query # # COMMIT
master-bin.000001 # Query # # use `test`; FLUSH TABLES master-bin.000001 # Query # # use `test`; FLUSH TABLES
insert delayed into t1 values (null),(null),(null),(null); insert delayed into t1 values (null),(null),(null),(null);
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses INSERT DELAYED. This is unsafe because the time when rows are inserted cannot be predicted. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. The statement is unsafe because it uses INSERT DELAYED. This is unsafe because the times when rows are inserted cannot be predicted.
insert delayed into t1 values (null),(null),(400),(null); insert delayed into t1 values (null),(null),(400),(null);
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses INSERT DELAYED. This is unsafe because the time when rows are inserted cannot be predicted. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. The statement is unsafe because it uses INSERT DELAYED. This is unsafe because the times when rows are inserted cannot be predicted.
select * from t1; select * from t1;
a a
207 207
......
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); CALL mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
drop table if exists t1,t2; drop table if exists t1,t2;
CREATE TABLE t1 ( CREATE TABLE t1 (
Period smallint(4) unsigned zerofill DEFAULT '0000' NOT NULL, Period smallint(4) unsigned zerofill DEFAULT '0000' NOT NULL,
......
...@@ -25,11 +25,11 @@ use b42829; ...@@ -25,11 +25,11 @@ use b42829;
### binlog-do-db is not filtering used database ### binlog-do-db is not filtering used database
BEGIN; BEGIN;
INSERT INTO t2 VALUES (1,2), (1,3), (1,4); INSERT INTO t2 VALUES (1,2), (1,3), (1,4);
ERROR HY000: Cannot execute statement: binlogging impossible since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED. ERROR HY000: Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-based logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED.
UPDATE b42829_filtered.t1 ft1, b42829.t1 nft1 SET ft1.x=1, nft1.x=2; UPDATE b42829_filtered.t1 ft1, b42829.t1 nft1 SET ft1.x=1, nft1.x=2;
ERROR HY000: Cannot execute statement: binlogging impossible since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED. ERROR HY000: Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-based logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED.
INSERT INTO t1 SELECT * FROM t2; INSERT INTO t1 SELECT * FROM t2;
ERROR HY000: Cannot execute statement: binlogging impossible since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED. ERROR HY000: Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = STATEMENT and at least one table uses a storage engine limited to row-based logging. InnoDB is limited to row-logging when transaction isolation level is READ COMMITTED or READ UNCOMMITTED.
COMMIT; COMMIT;
### assertion: filtered events did not make into the binlog ### assertion: filtered events did not make into the binlog
show binlog events from <binlog_start>; show binlog events from <binlog_start>;
......
...@@ -11,7 +11,7 @@ prepare s from "insert into t1 select 100 limit ?"; ...@@ -11,7 +11,7 @@ prepare s from "insert into t1 select 100 limit ?";
set @a=100; set @a=100;
execute s using @a; execute s using @a;
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses a LIMIT clause. This is unsafe because the set of rows included cannot be predicted. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. The statement is unsafe because it uses a LIMIT clause. This is unsafe because the set of rows included cannot be predicted.
show binlog events from <binlog_start>; show binlog events from <binlog_start>;
Log_name Pos Event_type Server_id End_log_pos Info Log_name Pos Event_type Server_id End_log_pos Info
master-bin.000001 # Query # # use `test`; create table t1 (a int) master-bin.000001 # Query # # use `test`; create table t1 (a int)
......
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); CALL mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
DROP TABLE IF EXISTS t1; DROP TABLE IF EXISTS t1;
DROP TABLE IF EXISTS t2; DROP TABLE IF EXISTS t2;
set @saved_global_binlog_format = @@global.binlog_format; set @saved_global_binlog_format = @@global.binlog_format;
...@@ -31,7 +31,7 @@ RELEASE_LOCK('Bug#34306') ...@@ -31,7 +31,7 @@ RELEASE_LOCK('Bug#34306')
1 1
# con2 # con2
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses a system function whose value may differ on slave. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it uses a system function that may return a different value on the slave.
SELECT RELEASE_LOCK('Bug#34306'); SELECT RELEASE_LOCK('Bug#34306');
RELEASE_LOCK('Bug#34306') RELEASE_LOCK('Bug#34306')
1 1
......
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses a LIMIT clause. This is unsafe because the set of rows included cannot be predicted. .*"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT.");
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses a system function whose value may differ on slave. .*");
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement invokes a trigger or a stored function that inserts into AUTO_INCREMENT column");
### NOT filtered database => assertion: warnings ARE shown ### NOT filtered database => assertion: warnings ARE shown
DROP TABLE IF EXISTS t1; DROP TABLE IF EXISTS t1;
CREATE TABLE t1 (a int, b int, primary key (a)); CREATE TABLE t1 (a int, b int, primary key (a));
INSERT INTO t1 VALUES (1,2), (2,3); INSERT INTO t1 VALUES (1,2), (2,3);
UPDATE t1 SET b='4' WHERE a=1 LIMIT 1; UPDATE t1 SET b='4' WHERE a=1 LIMIT 1;
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses a LIMIT clause. This is unsafe because the set of rows included cannot be predicted. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. The statement is unsafe because it uses a LIMIT clause. This is unsafe because the set of rows included cannot be predicted.
UPDATE t1 SET b='5' WHERE a=2 ORDER BY a LIMIT 1; UPDATE t1 SET b='5' WHERE a=2 ORDER BY a LIMIT 1;
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses a LIMIT clause. This is unsafe because the set of rows included cannot be predicted. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. The statement is unsafe because it uses a LIMIT clause. This is unsafe because the set of rows included cannot be predicted.
DROP TABLE t1; DROP TABLE t1;
### NOT filtered database => assertion: binlog disabled and warnings ARE NOT shown ### NOT filtered database => assertion: binlog disabled and warnings ARE NOT shown
SET SQL_LOG_BIN= 0; SET SQL_LOG_BIN= 0;
...@@ -41,11 +39,11 @@ CREATE TABLE t1 (a VARCHAR(36), b VARCHAR(10)); ...@@ -41,11 +39,11 @@ CREATE TABLE t1 (a VARCHAR(36), b VARCHAR(10));
SET GLOBAL LOG_WARNINGS = 0; SET GLOBAL LOG_WARNINGS = 0;
INSERT INTO t1 VALUES(UUID(), 'Bug#46265'); INSERT INTO t1 VALUES(UUID(), 'Bug#46265');
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses a system function whose value may differ on slave. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it uses a system function that may return a different value on the slave.
SET GLOBAL LOG_WARNINGS = 1; SET GLOBAL LOG_WARNINGS = 1;
INSERT INTO t1 VALUES(UUID(), 'Bug#46265'); INSERT INTO t1 VALUES(UUID(), 'Bug#46265');
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses a system function whose value may differ on slave. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it uses a system function that may return a different value on the slave.
DROP TABLE t1; DROP TABLE t1;
SET GLOBAL log_warnings = @old_log_warnings; SET GLOBAL log_warnings = @old_log_warnings;
# Count the number of times the "Unsafe" message was printed # Count the number of times the "Unsafe" message was printed
...@@ -62,18 +60,18 @@ RETURN 1; ...@@ -62,18 +60,18 @@ RETURN 1;
END | END |
INSERT INTO t1 VALUES (0); INSERT INTO t1 VALUES (0);
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement invokes a trigger or a stored function that inserts into AUTO_INCREMENT column which is unsafe to binlog in STATEMENT format because slave may execute it non-deterministically. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it invokes a trigger or a stored function that inserts into an AUTO_INCREMENT column. Inserted values cannot be logged correctly.
SHOW WARNINGS; SHOW WARNINGS;
Level Code Message Level Code Message
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement invokes a trigger or a stored function that inserts into AUTO_INCREMENT column which is unsafe to binlog in STATEMENT format because slave may execute it non-deterministically. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it invokes a trigger or a stored function that inserts into an AUTO_INCREMENT column. Inserted values cannot be logged correctly.
SELECT sf_bug50192(); SELECT sf_bug50192();
sf_bug50192() sf_bug50192()
1 1
Warnings: Warnings:
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement invokes a trigger or a stored function that inserts into AUTO_INCREMENT column which is unsafe to binlog in STATEMENT format because slave may execute it non-deterministically. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it invokes a trigger or a stored function that inserts into an AUTO_INCREMENT column. Inserted values cannot be logged correctly.
SHOW WARNINGS; SHOW WARNINGS;
Level Code Message Level Code Message
Note 1592 Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement invokes a trigger or a stored function that inserts into AUTO_INCREMENT column which is unsafe to binlog in STATEMENT format because slave may execute it non-deterministically. Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it invokes a trigger or a stored function that inserts into an AUTO_INCREMENT column. Inserted values cannot be logged correctly.
DROP FUNCTION sf_bug50192; DROP FUNCTION sf_bug50192;
DROP TRIGGER tr_bug50192; DROP TRIGGER tr_bug50192;
DROP TABLE t1, t2; DROP TABLE t1, t2;
RESET MASTER;
create table foo (a int); create table foo (a int);
flush logs; flush logs;
create temporary table tmp1_foo like foo; create temporary table tmp1_foo like foo;
......
This source diff could not be displayed because it is too large. You can view the blob instead.
-- source include/have_innodb.inc -- source include/have_innodb.inc
-- source include/have_binlog_format_statement.inc -- source include/have_binlog_format_statement.inc
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
# You cannot use `KILL' with the Embedded MySQL Server library, # You cannot use `KILL' with the Embedded MySQL Server library,
# because the embedded server merely runs inside the threads of the host # because the embedded server merely runs inside the threads of the host
......
...@@ -7,7 +7,7 @@ source include/have_blackhole.inc; ...@@ -7,7 +7,7 @@ source include/have_blackhole.inc;
source include/have_ndb.inc; source include/have_ndb.inc;
source include/have_log_bin.inc; source include/have_log_bin.inc;
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
CREATE TABLE t1m (m INT, n INT) ENGINE=MYISAM; CREATE TABLE t1m (m INT, n INT) ENGINE=MYISAM;
CREATE TABLE t1b (b INT, c INT) ENGINE=BLACKHOLE; CREATE TABLE t1b (b INT, c INT) ENGINE=BLACKHOLE;
......
...@@ -7,6 +7,6 @@ ...@@ -7,6 +7,6 @@
reset master; # get rid of previous tests binlog reset master; # get rid of previous tests binlog
-- enable_query_log -- enable_query_log
disable_query_log; disable_query_log;
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
enable_query_log; enable_query_log;
-- source extra/binlog_tests/binlog_insert_delayed.test -- source extra/binlog_tests/binlog_insert_delayed.test
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
-- source include/have_binlog_format_statement.inc -- source include/have_binlog_format_statement.inc
disable_query_log; disable_query_log;
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
enable_query_log; enable_query_log;
-- disable_query_log -- disable_query_log
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
# Test sets its own binlog_format, so we restrict it to run only once # Test sets its own binlog_format, so we restrict it to run only once
--source include/have_binlog_format_row.inc --source include/have_binlog_format_row.inc
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); CALL mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
# Get rid of previous tests binlog # Get rid of previous tests binlog
--disable_query_log --disable_query_log
......
...@@ -25,9 +25,7 @@ ...@@ -25,9 +25,7 @@
-- source include/have_log_bin.inc -- source include/have_log_bin.inc
-- source include/have_binlog_format_statement.inc -- source include/have_binlog_format_statement.inc
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses a LIMIT clause. This is unsafe because the set of rows included cannot be predicted. .*"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT.");
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement uses a system function whose value may differ on slave. .*");
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT. Reason for unsafeness: Statement invokes a trigger or a stored function that inserts into AUTO_INCREMENT column");
-- echo ### NOT filtered database => assertion: warnings ARE shown -- echo ### NOT filtered database => assertion: warnings ARE shown
......
...@@ -28,8 +28,10 @@ ...@@ -28,8 +28,10 @@
source include/have_log_bin.inc; source include/have_log_bin.inc;
source include/have_binlog_format_mixed_or_statement.inc; source include/have_binlog_format_mixed_or_statement.inc;
RESET MASTER;
--disable_query_log --disable_query_log
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT"); CALL mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
--enable_query_log --enable_query_log
connect (master,127.0.0.1,root,,test,$MASTER_MYPORT,); connect (master,127.0.0.1,root,,test,$MASTER_MYPORT,);
...@@ -71,6 +73,8 @@ truncate table tmp1_foo; ...@@ -71,6 +73,8 @@ truncate table tmp1_foo;
connection master1; connection master1;
truncate table tmp2_foo; truncate table tmp2_foo;
let $binlog_file= query_get_value(SHOW MASTER STATUS, File, 1);
flush logs; flush logs;
connection default; connection default;
...@@ -82,7 +86,7 @@ create table foo (a int); ...@@ -82,7 +86,7 @@ create table foo (a int);
# replay from binary log # replay from binary log
let $MYSQLD_DATADIR= `select @@datadir`; let $MYSQLD_DATADIR= `select @@datadir`;
exec $MYSQL_BINLOG $MYSQLD_DATADIR/master-bin.000002 | $MYSQL; exec $MYSQL_BINLOG $MYSQLD_DATADIR/$binlog_file | $MYSQL;
select * from foo; select * from foo;
# clean up # clean up
......
...@@ -78,7 +78,7 @@ ...@@ -78,7 +78,7 @@
# BUG#45825: INSERT DELAYED is not unsafe: logged in statement format # BUG#45825: INSERT DELAYED is not unsafe: logged in statement format
# BUG#45785: LIMIT in SP does not cause RBL if binlog_format=MIXED # BUG#45785: LIMIT in SP does not cause RBL if binlog_format=MIXED
# BUG#47995: Mark user functions as unsafe # BUG#47995: Mark user functions as unsafe
# BUG#49222: Mare RAND() unsafe # BUG#49222: Mark RAND() unsafe
# #
# ==== Related test cases ==== # ==== Related test cases ====
# #
...@@ -90,15 +90,15 @@ ...@@ -90,15 +90,15 @@
# actually can be replicated safely in statement mode. # actually can be replicated safely in statement mode.
# #
# rpl_ndb.rpl_ndb_binlog_format_errors tests all errors and warnings # rpl_ndb.rpl_ndb_binlog_format_errors tests all errors and warnings
# related to logging format (not just 'Unsafe statement binlogged in # related to logging format (not just 'Unsafe statement written to the
# statement mode since BINLOG_FORMAT = STATEMENT'). # binary log using statement format since BINLOG_FORMAT = STATEMENT').
--source include/have_udf.inc --source include/have_udf.inc
--source include/have_log_bin.inc --source include/have_log_bin.inc
--source include/have_binlog_format_statement.inc --source include/have_binlog_format_statement.inc
--disable_query_log --disable_query_log
call mtr.add_suppression("Unsafe statement binlogged in statement format"); call mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT");
--enable_query_log --enable_query_log
--echo #### Setup tables #### --echo #### Setup tables ####
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -2,102 +2,114 @@ DROP DATABASE IF EXISTS d11; ...@@ -2,102 +2,114 @@ DROP DATABASE IF EXISTS d11;
CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin; CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 ascii ascii_bin NULL def d11 ascii ascii_bin NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
ALTER DATABASE d11 CHARACTER SET utf8 COLLATE utf8_general_ci; ALTER DATABASE d11 CHARACTER SET utf8 COLLATE utf8_general_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 utf8 utf8_general_ci NULL def d11 utf8 utf8_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d11; DROP DATABASE d11;
CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin; CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 ascii ascii_bin NULL def d11 ascii ascii_bin NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
ALTER DATABASE d11 CHARACTER SET latin2 COLLATE latin2_general_ci; ALTER DATABASE d11 CHARACTER SET latin2 COLLATE latin2_general_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 latin2 latin2_general_ci NULL def d11 latin2 latin2_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d11; DROP DATABASE d11;
CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin; CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 ascii ascii_bin NULL def d11 ascii ascii_bin NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
ALTER DATABASE d11 CHARACTER SET cp1250 COLLATE cp1250_croatian_ci; ALTER DATABASE d11 CHARACTER SET cp1250 COLLATE cp1250_croatian_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 cp1250 cp1250_croatian_ci NULL def d11 cp1250 cp1250_croatian_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d11; DROP DATABASE d11;
CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin; CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 ascii ascii_bin NULL def d11 ascii ascii_bin NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
ALTER SCHEMA d11 CHARACTER SET utf8 COLLATE utf8_general_ci; ALTER SCHEMA d11 CHARACTER SET utf8 COLLATE utf8_general_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 utf8 utf8_general_ci NULL def d11 utf8 utf8_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d11; DROP DATABASE d11;
CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin; CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 ascii ascii_bin NULL def d11 ascii ascii_bin NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
ALTER SCHEMA d11 CHARACTER SET latin2 COLLATE latin2_general_ci; ALTER SCHEMA d11 CHARACTER SET latin2 COLLATE latin2_general_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 latin2 latin2_general_ci NULL def d11 latin2 latin2_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d11; DROP DATABASE d11;
CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin; CREATE DATABASE d11 DEFAULT CHARACTER SET ascii DEFAULT COLLATE ascii_bin;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 ascii ascii_bin NULL def d11 ascii ascii_bin NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
ALTER SCHEMA d11 CHARACTER SET cp1250 COLLATE cp1250_croatian_ci; ALTER SCHEMA d11 CHARACTER SET cp1250 COLLATE cp1250_croatian_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d11 cp1250 cp1250_croatian_ci NULL def d11 cp1250 cp1250_croatian_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d11; DROP DATABASE d11;
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -2,90 +2,100 @@ DROP DATABASE IF EXISTS d12; ...@@ -2,90 +2,100 @@ DROP DATABASE IF EXISTS d12;
CREATE DATABASE d12 CHARACTER SET ascii; CREATE DATABASE d12 CHARACTER SET ascii;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d12 ascii ascii_general_ci NULL def d12 ascii ascii_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d12; DROP DATABASE d12;
CREATE DATABASE d12 CHARACTER SET utf8; CREATE DATABASE d12 CHARACTER SET utf8;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d12 utf8 utf8_general_ci NULL def d12 utf8 utf8_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d12; DROP DATABASE d12;
CREATE DATABASE d12 CHARACTER SET binary; CREATE DATABASE d12 CHARACTER SET binary;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d12 binary binary NULL def d12 binary binary NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d12; DROP DATABASE d12;
CREATE DATABASE d12 CHARACTER SET swe7; CREATE DATABASE d12 CHARACTER SET swe7;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d12 swe7 swe7_swedish_ci NULL def d12 swe7 swe7_swedish_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d12; DROP DATABASE d12;
CREATE DATABASE d12 CHARACTER SET cp1251; CREATE DATABASE d12 CHARACTER SET cp1251;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d12 cp1251 cp1251_general_ci NULL def d12 cp1251 cp1251_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d12; DROP DATABASE d12;
CREATE SCHEMA d12 CHARACTER SET ascii; CREATE SCHEMA d12 CHARACTER SET ascii;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d12 ascii ascii_general_ci NULL def d12 ascii ascii_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP SCHEMA d12; DROP SCHEMA d12;
CREATE SCHEMA d12 CHARACTER SET utf8; CREATE SCHEMA d12 CHARACTER SET utf8;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d12 utf8 utf8_general_ci NULL def d12 utf8 utf8_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP SCHEMA d12; DROP SCHEMA d12;
CREATE SCHEMA d12 CHARACTER SET binary; CREATE SCHEMA d12 CHARACTER SET binary;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d12 binary binary NULL def d12 binary binary NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP SCHEMA d12; DROP SCHEMA d12;
CREATE SCHEMA d12 CHARACTER SET swe7; CREATE SCHEMA d12 CHARACTER SET swe7;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d12 swe7 swe7_swedish_ci NULL def d12 swe7 swe7_swedish_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP SCHEMA d12; DROP SCHEMA d12;
CREATE SCHEMA d12 CHARACTER SET cp1251; CREATE SCHEMA d12 CHARACTER SET cp1251;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d12 cp1251 cp1251_general_ci NULL def d12 cp1251 cp1251_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP SCHEMA d12; DROP SCHEMA d12;
...@@ -2,54 +2,60 @@ DROP DATABASE IF EXISTS d13; ...@@ -2,54 +2,60 @@ DROP DATABASE IF EXISTS d13;
CREATE DATABASE d13 CHARACTER SET utf8 COLLATE utf8_general_ci; CREATE DATABASE d13 CHARACTER SET utf8 COLLATE utf8_general_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d13 utf8 utf8_general_ci NULL def d13 utf8 utf8_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d13; DROP DATABASE d13;
CREATE DATABASE d13 CHARACTER SET latin2 COLLATE latin2_general_ci; CREATE DATABASE d13 CHARACTER SET latin2 COLLATE latin2_general_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d13 latin2 latin2_general_ci NULL def d13 latin2 latin2_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d13; DROP DATABASE d13;
CREATE DATABASE d13 CHARACTER SET cp1250 COLLATE cp1250_croatian_ci; CREATE DATABASE d13 CHARACTER SET cp1250 COLLATE cp1250_croatian_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d13 cp1250 cp1250_croatian_ci NULL def d13 cp1250 cp1250_croatian_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP DATABASE d13; DROP DATABASE d13;
CREATE SCHEMA d13 CHARACTER SET utf8 COLLATE utf8_general_ci; CREATE SCHEMA d13 CHARACTER SET utf8 COLLATE utf8_general_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d13 utf8 utf8_general_ci NULL def d13 utf8 utf8_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP SCHEMA d13; DROP SCHEMA d13;
CREATE SCHEMA d13 CHARACTER SET latin2 COLLATE latin2_general_ci; CREATE SCHEMA d13 CHARACTER SET latin2 COLLATE latin2_general_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d13 latin2 latin2_general_ci NULL def d13 latin2 latin2_general_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP SCHEMA d13; DROP SCHEMA d13;
CREATE SCHEMA d13 CHARACTER SET cp1250 COLLATE cp1250_croatian_ci; CREATE SCHEMA d13 CHARACTER SET cp1250 COLLATE cp1250_croatian_ci;
SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME; SELECT * FROM INFORMATION_SCHEMA.SCHEMATA ORDER BY SCHEMA_NAME;
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
NULL d13 cp1250 cp1250_croatian_ci NULL def d13 cp1250 cp1250_croatian_ci NULL
NULL information_schema utf8 utf8_general_ci NULL def information_schema utf8 utf8_general_ci NULL
NULL mtr latin1 latin1_swedish_ci NULL def mtr latin1 latin1_swedish_ci NULL
NULL mysql latin1 latin1_swedish_ci NULL def mysql latin1 latin1_swedish_ci NULL
NULL test latin1 latin1_swedish_ci NULL def performance_schema utf8 utf8_general_ci NULL
def test latin1 latin1_swedish_ci NULL
DROP SCHEMA d13; DROP SCHEMA d13;
...@@ -6,6 +6,7 @@ information_schema ...@@ -6,6 +6,7 @@ information_schema
d1 d1
mtr mtr
mysql mysql
performance_schema
test test
SHOW DATABASES LIKE 'd%'; SHOW DATABASES LIKE 'd%';
Database (d%) Database (d%)
...@@ -16,6 +17,7 @@ information_schema ...@@ -16,6 +17,7 @@ information_schema
d1 d1
mtr mtr
mysql mysql
performance_schema
test test
USE d1; USE d1;
DROP DATABASE d1; DROP DATABASE d1;
...@@ -26,6 +28,7 @@ information_schema ...@@ -26,6 +28,7 @@ information_schema
d1 d1
mtr mtr
mysql mysql
performance_schema
test test
SHOW SCHEMAS LIKE 'd%'; SHOW SCHEMAS LIKE 'd%';
Database (d%) Database (d%)
...@@ -36,6 +39,7 @@ information_schema ...@@ -36,6 +39,7 @@ information_schema
d1 d1
mtr mtr
mysql mysql
performance_schema
test test
USE d1; USE d1;
DROP SCHEMA d1; DROP SCHEMA d1;
...@@ -6,6 +6,7 @@ information_schema ...@@ -6,6 +6,7 @@ information_schema
d4 d4
mtr mtr
mysql mysql
performance_schema
test test
CREATE DATABASE d4; CREATE DATABASE d4;
ERROR HY000: Can't create database 'd4'; database exists ERROR HY000: Can't create database 'd4'; database exists
...@@ -15,4 +16,5 @@ Database ...@@ -15,4 +16,5 @@ Database
information_schema information_schema
mtr mtr
mysql mysql
performance_schema
test test
...@@ -3,6 +3,7 @@ Database ...@@ -3,6 +3,7 @@ Database
information_schema information_schema
mtr mtr
mysql mysql
performance_schema
test test
CREATE DATABASE mysql; CREATE DATABASE mysql;
ERROR HY000: Can't create database 'mysql'; database exists ERROR HY000: Can't create database 'mysql'; database exists
...@@ -11,4 +12,5 @@ Database ...@@ -11,4 +12,5 @@ Database
information_schema information_schema
mtr mtr
mysql mysql
performance_schema
test test
...@@ -9,6 +9,7 @@ information_schema ...@@ -9,6 +9,7 @@ information_schema
d2 d2
mtr mtr
mysql mysql
performance_schema
test test
USE d2; USE d2;
DROP DATABASE d2; DROP DATABASE d2;
...@@ -25,6 +26,7 @@ information_schema ...@@ -25,6 +26,7 @@ information_schema
d2 d2
mtr mtr
mysql mysql
performance_schema
test test
USE d2; USE d2;
DROP SCHEMA d2; DROP SCHEMA d2;
......
...@@ -6,6 +6,7 @@ information_schema ...@@ -6,6 +6,7 @@ information_schema
d5 d5
mtr mtr
mysql mysql
performance_schema
test test
DROP DATABASE nond5; DROP DATABASE nond5;
ERROR HY000: Can't drop database 'nond5'; database doesn't exist ERROR HY000: Can't drop database 'nond5'; database doesn't exist
...@@ -15,4 +16,5 @@ Database ...@@ -15,4 +16,5 @@ Database
information_schema information_schema
mtr mtr
mysql mysql
performance_schema
test test
...@@ -6,6 +6,7 @@ information_schema ...@@ -6,6 +6,7 @@ information_schema
d6 d6
mtr mtr
mysql mysql
performance_schema
test test
USE DATABASE nond6; USE DATABASE nond6;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'DATABASE nond6' at line 1 ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'DATABASE nond6' at line 1
...@@ -15,4 +16,5 @@ Database ...@@ -15,4 +16,5 @@ Database
information_schema information_schema
mtr mtr
mysql mysql
performance_schema
test test
...@@ -55,12 +55,6 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc'); ...@@ -55,12 +55,6 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc'); INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def'); INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def');
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def'); INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
ERROR 23000: Duplicate entry 'abc' for key 'PRIMARY'
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
ERROR 23000: Duplicate entry 'abc' for key 'PRIMARY'
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
ERROR 23000: Duplicate entry 'abc' for key 'PRIMARY'
SELECT hex(c1),hex(c2),hex(c3) FROM t1; SELECT hex(c1),hex(c2),hex(c3) FROM t1;
hex(c1) hex(c2) hex(c3) hex(c1) hex(c2) hex(c3)
61626300000000000000 61626300000000000000 61626300000000000000 61626300000000000000 61626300000000000000 61626300000000000000
......
...@@ -55,12 +55,6 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc'); ...@@ -55,12 +55,6 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc'); INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def'); INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def');
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def'); INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
ERROR 23000: Duplicate entry 'abc' for key 'PRIMARY'
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
ERROR 23000: Duplicate entry 'abc' for key 'PRIMARY'
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
ERROR 23000: Duplicate entry 'abc' for key 'PRIMARY'
SELECT * FROM t1; SELECT * FROM t1;
c1 c2 c3 c1 c2 c3
abc abc
......
...@@ -55,12 +55,6 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc'); ...@@ -55,12 +55,6 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc'); INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def'); INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def');
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def'); INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
ERROR 23000: Duplicate entry 'abc' for key 'c1'
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
ERROR 23000: Duplicate entry 'abc' for key 'c1'
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
ERROR 23000: Duplicate entry 'abc' for key 'c1'
SELECT * FROM t1; SELECT * FROM t1;
c1 c2 c3 c1 c2 c3
abc abc
......
This diff is collapsed.
...@@ -7,7 +7,7 @@ start slave; ...@@ -7,7 +7,7 @@ start slave;
reset master; reset master;
show master status; show master status;
File Position Binlog_Do_DB Binlog_Ignore_DB File Position Binlog_Do_DB Binlog_Ignore_DB
master-bin.000001 106 master-bin.000001 107
stop slave; stop slave;
reset slave; reset slave;
show slave status; show slave status;
...@@ -49,6 +49,8 @@ Last_IO_Errno 0 ...@@ -49,6 +49,8 @@ Last_IO_Errno 0
Last_IO_Error Last_IO_Error
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
change master to master_host='127.0.0.1'; change master to master_host='127.0.0.1';
show slave status; show slave status;
Slave_IO_State # Slave_IO_State #
...@@ -89,6 +91,8 @@ Last_IO_Errno 0 ...@@ -89,6 +91,8 @@ Last_IO_Errno 0
Last_IO_Error Last_IO_Error
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
change master to master_host='127.0.0.1',master_user='root', change master to master_host='127.0.0.1',master_user='root',
master_password='',master_port=MASTER_PORT; master_password='',master_port=MASTER_PORT;
show slave status; show slave status;
...@@ -130,6 +134,8 @@ Last_IO_Errno 0 ...@@ -130,6 +134,8 @@ Last_IO_Errno 0
Last_IO_Error Last_IO_Error
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
start slave; start slave;
show slave status; show slave status;
Slave_IO_State Waiting for master to send event Slave_IO_State Waiting for master to send event
...@@ -138,9 +144,9 @@ Master_User root ...@@ -138,9 +144,9 @@ Master_User root
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 1 Connect_Retry 1
Master_Log_File master-bin.000001 Master_Log_File master-bin.000001
Read_Master_Log_Pos 106 Read_Master_Log_Pos 107
Relay_Log_File slave-relay-bin.000002 Relay_Log_File slave-relay-bin.000002
Relay_Log_Pos 252 Relay_Log_Pos 254
Relay_Master_Log_File master-bin.000001 Relay_Master_Log_File master-bin.000001
Slave_IO_Running Yes Slave_IO_Running Yes
Slave_SQL_Running Yes Slave_SQL_Running Yes
...@@ -153,8 +159,8 @@ Replicate_Wild_Ignore_Table ...@@ -153,8 +159,8 @@ Replicate_Wild_Ignore_Table
Last_Errno 0 Last_Errno 0
Last_Error Last_Error
Skip_Counter 0 Skip_Counter 0
Exec_Master_Log_Pos 106 Exec_Master_Log_Pos 107
Relay_Log_Space 407 Relay_Log_Space 410
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
Until_Log_Pos 0 Until_Log_Pos 0
...@@ -170,6 +176,8 @@ Last_IO_Errno 0 ...@@ -170,6 +176,8 @@ Last_IO_Errno 0
Last_IO_Error Last_IO_Error
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
drop table if exists t1; drop table if exists t1;
create table t1 (n int, PRIMARY KEY(n)); create table t1 (n int, PRIMARY KEY(n));
insert into t1 values (10),(45),(90); insert into t1 values (10),(45),(90);
......
...@@ -12,12 +12,12 @@ insert into t1 values(1); ...@@ -12,12 +12,12 @@ insert into t1 values(1);
insert into t1 values(2); insert into t1 values(2);
stop slave; stop slave;
show slave status; show slave status;
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 # # # master-bin.000001 No No 0 0 191 # None 0 No # No 0 0 # 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 # # # master-bin.000001 No No 0 0 192 # None 0 No # No 0 0 1
change master to master_user='root'; change master to master_user='root';
show slave status; show slave status;
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id
# 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 # # # master-bin.000001 No No 0 0 191 # None 0 No # No 0 0 # 127.0.0.1 root MASTER_MYPORT 1 master-bin.000001 # # # master-bin.000001 No No 0 0 192 # None 0 No # No 0 0 1
start slave; start slave;
select * from t1; select * from t1;
n n
......
...@@ -28,6 +28,7 @@ mysql ...@@ -28,6 +28,7 @@ mysql
mysqltest_bob mysqltest_bob
mysqltest_prometheus mysqltest_prometheus
mysqltest_sisyfos mysqltest_sisyfos
performance_schema
test test
SHOW DATABASES; SHOW DATABASES;
Database Database
...@@ -36,6 +37,7 @@ mtr ...@@ -36,6 +37,7 @@ mtr
mysql mysql
mysqltest_prometheus mysqltest_prometheus
mysqltest_sisyfos mysqltest_sisyfos
performance_schema
test test
DROP DATABASE IF EXISTS mysqltest_sisyfos; DROP DATABASE IF EXISTS mysqltest_sisyfos;
USE mysqltest_prometheus; USE mysqltest_prometheus;
...@@ -52,6 +54,7 @@ mysql ...@@ -52,6 +54,7 @@ mysql
mysqltest_bob mysqltest_bob
mysqltest_prometheus mysqltest_prometheus
mysqltest_sisyfos mysqltest_sisyfos
performance_schema
test test
SHOW DATABASES; SHOW DATABASES;
Database Database
...@@ -60,6 +63,7 @@ mtr ...@@ -60,6 +63,7 @@ mtr
mysql mysql
mysqltest_prometheus mysqltest_prometheus
mysqltest_sisyfos mysqltest_sisyfos
performance_schema
test test
USE mysqltest_prometheus; USE mysqltest_prometheus;
SHOW TABLES; SHOW TABLES;
......
...@@ -24,7 +24,7 @@ Master_User root ...@@ -24,7 +24,7 @@ Master_User root
Master_Port SLAVE_PORT Master_Port SLAVE_PORT
Connect_Retry 60 Connect_Retry 60
Master_Log_File slave-bin.000001 Master_Log_File slave-bin.000001
Read_Master_Log_Pos 106 Read_Master_Log_Pos 107
Relay_Log_File # Relay_Log_File #
Relay_Log_Pos # Relay_Log_Pos #
Relay_Master_Log_File slave-bin.000001 Relay_Master_Log_File slave-bin.000001
...@@ -39,7 +39,7 @@ Replicate_Wild_Ignore_Table ...@@ -39,7 +39,7 @@ Replicate_Wild_Ignore_Table
Last_Errno 0 Last_Errno 0
Last_Error Last_Error
Skip_Counter 0 Skip_Counter 0
Exec_Master_Log_Pos 106 Exec_Master_Log_Pos 107
Relay_Log_Space # Relay_Log_Space #
Until_Condition None Until_Condition None
Until_Log_File Until_Log_File
...@@ -56,4 +56,6 @@ Last_IO_Errno 0 ...@@ -56,4 +56,6 @@ Last_IO_Errno 0
Last_IO_Error Last_IO_Error
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 2
STOP SLAVE; STOP SLAVE;
...@@ -24,6 +24,7 @@ information_schema ...@@ -24,6 +24,7 @@ information_schema
mtr mtr
mysql mysql
mysqltest mysqltest
performance_schema
test test
USE test; USE test;
SHOW TABLES; SHOW TABLES;
......
...@@ -10,6 +10,6 @@ load data infile '../../std_data/rpl_loaddata.dat' into table test.t1; ...@@ -10,6 +10,6 @@ load data infile '../../std_data/rpl_loaddata.dat' into table test.t1;
select count(*) from test.t1; select count(*) from test.t1;
count(*) count(*)
2 2
show binlog events from 106; show binlog events from 107;
Log_name Pos Event_type Server_id End_log_pos Info Log_name Pos Event_type Server_id End_log_pos Info
drop table test.t1; drop table test.t1;
...@@ -6,37 +6,37 @@ drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; ...@@ -6,37 +6,37 @@ drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
start slave; start slave;
show master status; show master status;
File Position Binlog_Do_DB Binlog_Ignore_DB File Position Binlog_Do_DB Binlog_Ignore_DB
master-bin.000001 106 <Binlog_Ignore_DB> master-bin.000001 107 <Binlog_Ignore_DB>
show slave status; show slave status;
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 106 # # master-bin.000001 Yes Yes 0 0 106 # None 0 No # No 0 0 # 127.0.0.1 root MASTER_PORT 1 master-bin.000001 107 # # master-bin.000001 Yes Yes 0 0 107 # None 0 No # No 0 0 1
stop slave; stop slave;
change master to master_log_pos=106; change master to master_log_pos=107;
start slave; start slave;
stop slave; stop slave;
change master to master_log_pos=106; change master to master_log_pos=107;
show slave status; show slave status;
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 106 # # master-bin.000001 No No 0 0 106 # None 0 No # No 0 0 # 127.0.0.1 root MASTER_PORT 1 master-bin.000001 107 # # master-bin.000001 No No 0 0 107 # None 0 No # No 0 0 1
start slave; start slave;
show slave status; show slave status;
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 106 # # master-bin.000001 Yes Yes 0 0 106 # None 0 No # No 0 0 # 127.0.0.1 root MASTER_PORT 1 master-bin.000001 107 # # master-bin.000001 Yes Yes 0 0 107 # None 0 No # No 0 0 1
stop slave; stop slave;
change master to master_log_pos=177; change master to master_log_pos=178;
start slave; start slave;
show slave status; show slave status;
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id
# 127.0.0.1 root MASTER_PORT 1 master-bin.000001 177 # # master-bin.000001 No Yes 0 0 177 # None 0 No # No 1236 Got fatal error 1236 from master when reading data from binary log: 'Client requested master to start replication from impossible position' 0 # 127.0.0.1 root MASTER_PORT 1 master-bin.000001 178 # # master-bin.000001 No Yes 0 0 178 # None 0 No # No 1236 Got fatal error 1236 from master when reading data from binary log: 'Client requested master to start replication from impossible position' 0 1
show master status; show master status;
File Position Binlog_Do_DB Binlog_Ignore_DB File Position Binlog_Do_DB Binlog_Ignore_DB
master-bin.000001 106 <Binlog_Ignore_DB> master-bin.000001 107 <Binlog_Ignore_DB>
create table if not exists t1 (n int); create table if not exists t1 (n int);
drop table if exists t1; drop table if exists t1;
create table t1 (n int); create table t1 (n int);
insert into t1 values (1),(2),(3); insert into t1 values (1),(2),(3);
stop slave; stop slave;
change master to master_log_pos=206; change master to master_log_pos=207;
start slave; start slave;
select * from t1 ORDER BY n; select * from t1 ORDER BY n;
n n
......
...@@ -16,7 +16,7 @@ DELETE alias FROM a alias WHERE alias.i=1; ...@@ -16,7 +16,7 @@ DELETE alias FROM a alias WHERE alias.i=1;
SELECT * FROM a; SELECT * FROM a;
i i
insert into a values(2),(3); insert into a values(2),(3);
delete a alias FROM a alias where alias.i=2; delete alias FROM a alias where alias.i=2;
select * from a; select * from a;
i i
3 3
......
...@@ -4,12 +4,6 @@ reset master; ...@@ -4,12 +4,6 @@ reset master;
reset slave; reset slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
start slave; start slave;
set @saved_binlog_format = @@global.binlog_format;
SET BINLOG_FORMAT=MIXED;
SET GLOBAL BINLOG_FORMAT=MIXED;
SELECT @@GLOBAL.BINLOG_FORMAT, @@SESSION.BINLOG_FORMAT;
@@GLOBAL.BINLOG_FORMAT @@SESSION.BINLOG_FORMAT
MIXED MIXED
**** On Master **** **** On Master ****
CREATE TABLE t1 (a INT, b LONG); CREATE TABLE t1 (a INT, b LONG);
INSERT INTO t1 VALUES (1,1), (2,2); INSERT INTO t1 VALUES (1,1), (2,2);
...@@ -55,6 +49,7 @@ Last_IO_Errno 0 ...@@ -55,6 +49,7 @@ Last_IO_Errno 0
Last_IO_Error Last_IO_Error
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
SHOW BINLOG EVENTS; SHOW BINLOG EVENTS;
DROP TABLE IF EXISTS t1; DROP TABLE IF EXISTS t1;
SET GLOBAL BINLOG_FORMAT=@saved_binlog_format;
set @saved_binlog_format = @@global.binlog_format;
SET SESSION BINLOG_FORMAT=ROW;
SET GLOBAL BINLOG_FORMAT=ROW;
stop slave; stop slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
reset master; reset master;
...@@ -20,6 +17,8 @@ reset slave; ...@@ -20,6 +17,8 @@ reset slave;
set @my_max_binlog_size= @@global.max_binlog_size; set @my_max_binlog_size= @@global.max_binlog_size;
set global max_binlog_size=8192; set global max_binlog_size=8192;
set global max_relay_log_size=8192-1; set global max_relay_log_size=8192-1;
Warnings:
Warning 1292 Truncated incorrect max_relay_log_size value: '8191'
select @@global.max_relay_log_size; select @@global.max_relay_log_size;
@@global.max_relay_log_size @@global.max_relay_log_size
4096 4096
...@@ -63,6 +62,8 @@ Last_IO_Errno # ...@@ -63,6 +62,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
# #
# Test 2 # Test 2
# #
...@@ -111,6 +112,8 @@ Last_IO_Errno # ...@@ -111,6 +112,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
# #
# Test 3: max_relay_log_size = 0 # Test 3: max_relay_log_size = 0
# #
...@@ -159,6 +162,8 @@ Last_IO_Errno # ...@@ -159,6 +162,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
# #
# Test 4: Tests below are mainly to ensure that we have not coded with wrong assumptions # Test 4: Tests below are mainly to ensure that we have not coded with wrong assumptions
# #
...@@ -204,6 +209,8 @@ Last_IO_Errno # ...@@ -204,6 +209,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
# #
# Test 5 # Test 5
# #
...@@ -250,6 +257,8 @@ Last_IO_Errno # ...@@ -250,6 +257,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
# #
# Test 6: one more rotation, to be sure Relay_Log_Space is correctly updated # Test 6: one more rotation, to be sure Relay_Log_Space is correctly updated
# #
...@@ -294,6 +303,8 @@ Last_IO_Errno # ...@@ -294,6 +303,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
flush logs; flush logs;
show master status; show master status;
File Position Binlog_Do_DB Binlog_Ignore_DB File Position Binlog_Do_DB Binlog_Ignore_DB
...@@ -302,4 +313,3 @@ set global max_binlog_size= @my_max_binlog_size; ...@@ -302,4 +313,3 @@ set global max_binlog_size= @my_max_binlog_size;
# #
# End of 4.1 tests # End of 4.1 tests
# #
SET GLOBAL BINLOG_FORMAT= @saved_binlog_format;
...@@ -9,8 +9,8 @@ reset master; ...@@ -9,8 +9,8 @@ reset master;
stop slave; stop slave;
change master to master_port=SLAVE_PORT; change master to master_port=SLAVE_PORT;
show slave status; show slave status;
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id
127.0.0.1 root SLAVE_PORT 1 4 slave-relay-bin.000001 4 No No # # 0 0 0 106 None 0 No NULL No 0 0 127.0.0.1 root SLAVE_PORT 1 4 slave-relay-bin.000001 4 No No # # 0 0 0 107 None 0 No NULL No 0 0 1
start slave; start slave;
insert into t1 values (1); insert into t1 values (1);
show status like "slave_running"; show status like "slave_running";
......
...@@ -9,8 +9,8 @@ reset master; ...@@ -9,8 +9,8 @@ reset master;
stop slave; stop slave;
change master to master_port=SLAVE_PORT; change master to master_port=SLAVE_PORT;
show slave status; show slave status;
Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id
127.0.0.1 root SLAVE_PORT 1 4 slave-relay-bin.000001 4 No No # 0 0 0 106 None 0 No NULL No 0 0 127.0.0.1 root SLAVE_PORT 1 4 slave-relay-bin.000001 4 No No # 0 0 0 107 None 0 No NULL No 0 0 1
start slave; start slave;
insert into t1 values (1); insert into t1 values (1);
select * from t1; select * from t1;
......
...@@ -29,7 +29,7 @@ Read_Master_Log_Pos # ...@@ -29,7 +29,7 @@ Read_Master_Log_Pos #
Relay_Log_File # Relay_Log_File #
Relay_Log_Pos # Relay_Log_Pos #
Relay_Master_Log_File master-bin.000001 Relay_Master_Log_File master-bin.000001
Slave_IO_Running No Slave_IO_Running Connecting
Slave_SQL_Running Yes Slave_SQL_Running Yes
Replicate_Do_DB Replicate_Do_DB
Replicate_Ignore_DB Replicate_Ignore_DB
...@@ -57,5 +57,7 @@ Last_IO_Errno # ...@@ -57,5 +57,7 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
drop table t1; drop table t1;
drop table t1; drop table t1;
...@@ -174,9 +174,6 @@ begin ...@@ -174,9 +174,6 @@ begin
return unix_timestamp(); return unix_timestamp();
end| end|
ERROR HY000: You do not have the SUPER privilege and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable) ERROR HY000: You do not have the SUPER privilege and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable)
set global log_bin_trust_routine_creators=1;
Warnings:
Warning 1287 The syntax '@@log_bin_trust_routine_creators' is deprecated and will be removed in MySQL 5.6. Please use '@@log_bin_trust_function_creators' instead
set global log_bin_trust_function_creators=0; set global log_bin_trust_function_creators=0;
set global log_bin_trust_function_creators=1; set global log_bin_trust_function_creators=1;
set global log_bin_trust_function_creators=1; set global log_bin_trust_function_creators=1;
......
...@@ -17,6 +17,8 @@ reset slave; ...@@ -17,6 +17,8 @@ reset slave;
set @my_max_binlog_size= @@global.max_binlog_size; set @my_max_binlog_size= @@global.max_binlog_size;
set global max_binlog_size=8192; set global max_binlog_size=8192;
set global max_relay_log_size=8192-1; set global max_relay_log_size=8192-1;
Warnings:
Warning 1292 Truncated incorrect max_relay_log_size value: '8191'
select @@global.max_relay_log_size; select @@global.max_relay_log_size;
@@global.max_relay_log_size @@global.max_relay_log_size
4096 4096
...@@ -60,6 +62,8 @@ Last_IO_Errno # ...@@ -60,6 +62,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
# #
# Test 2 # Test 2
# #
...@@ -108,6 +112,8 @@ Last_IO_Errno # ...@@ -108,6 +112,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
# #
# Test 3: max_relay_log_size = 0 # Test 3: max_relay_log_size = 0
# #
...@@ -156,6 +162,8 @@ Last_IO_Errno # ...@@ -156,6 +162,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
# #
# Test 4: Tests below are mainly to ensure that we have not coded with wrong assumptions # Test 4: Tests below are mainly to ensure that we have not coded with wrong assumptions
# #
...@@ -201,6 +209,8 @@ Last_IO_Errno # ...@@ -201,6 +209,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
# #
# Test 5 # Test 5
# #
...@@ -247,6 +257,8 @@ Last_IO_Errno # ...@@ -247,6 +257,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
# #
# Test 6: one more rotation, to be sure Relay_Log_Space is correctly updated # Test 6: one more rotation, to be sure Relay_Log_Space is correctly updated
# #
...@@ -291,6 +303,8 @@ Last_IO_Errno # ...@@ -291,6 +303,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
flush logs; flush logs;
show master status; show master status;
File Position Binlog_Do_DB Binlog_Ignore_DB File Position Binlog_Do_DB Binlog_Ignore_DB
......
...@@ -43,6 +43,8 @@ Last_IO_Errno # ...@@ -43,6 +43,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
stop slave; stop slave;
change master to master_user='test'; change master to master_user='test';
SHOW SLAVE STATUS; SHOW SLAVE STATUS;
...@@ -84,11 +86,13 @@ Last_IO_Errno # ...@@ -84,11 +86,13 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
reset slave; reset slave;
SHOW SLAVE STATUS; SHOW SLAVE STATUS;
Slave_IO_State # Slave_IO_State #
Master_Host 127.0.0.1 Master_Host 127.0.0.1
Master_User root Master_User test
Master_Port MASTER_PORT Master_Port MASTER_PORT
Connect_Retry 1 Connect_Retry 1
Master_Log_File Master_Log_File
...@@ -124,6 +128,9 @@ Last_IO_Errno # ...@@ -124,6 +128,9 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
change master to master_user='root';
start slave; start slave;
SHOW SLAVE STATUS; SHOW SLAVE STATUS;
Slave_IO_State # Slave_IO_State #
...@@ -164,6 +171,8 @@ Last_IO_Errno # ...@@ -164,6 +171,8 @@ Last_IO_Errno #
Last_IO_Error # Last_IO_Error #
Last_SQL_Errno 0 Last_SQL_Errno 0
Last_SQL_Error Last_SQL_Error
Replicate_Ignore_Server_Ids
Master_Server_Id 1
stop slave; stop slave;
reset slave; reset slave;
start slave; start slave;
......
...@@ -75,7 +75,7 @@ STATEMENT STATEMENT ...@@ -75,7 +75,7 @@ STATEMENT STATEMENT
set global binlog_format=default; set global binlog_format=default;
select @@global.binlog_format, @@session.binlog_format; select @@global.binlog_format, @@session.binlog_format;
@@global.binlog_format @@session.binlog_format @@global.binlog_format @@session.binlog_format
MIXED STATEMENT STATEMENT STATEMENT
prepare stmt1 from 'insert into t1 select ?'; prepare stmt1 from 'insert into t1 select ?';
set @string="emergency_12_"; set @string="emergency_12_";
insert into t1 values("work_13_"); insert into t1 values("work_13_");
...@@ -90,7 +90,7 @@ insert into t1 select "yesterday_16_"; ...@@ -90,7 +90,7 @@ insert into t1 select "yesterday_16_";
set binlog_format=mixed; set binlog_format=mixed;
select @@global.binlog_format, @@session.binlog_format; select @@global.binlog_format, @@session.binlog_format;
@@global.binlog_format @@session.binlog_format @@global.binlog_format @@session.binlog_format
MIXED MIXED STATEMENT MIXED
set global binlog_format=mixed; set global binlog_format=mixed;
select @@global.binlog_format, @@session.binlog_format; select @@global.binlog_format, @@session.binlog_format;
@@global.binlog_format @@session.binlog_format @@global.binlog_format @@session.binlog_format
......
...@@ -8,12 +8,12 @@ reset master; ...@@ -8,12 +8,12 @@ reset master;
CREATE USER ''@localhost; CREATE USER ''@localhost;
SET @save_select_limit=@@session.sql_select_limit; SET @save_select_limit=@@session.sql_select_limit;
SET @@session.sql_select_limit=10, @@session.pseudo_thread_id=100; SET @@session.sql_select_limit=10, @@session.pseudo_thread_id=100;
ERROR 42000: Access denied; you need the SUPER privilege for this operation ERROR 42000: Access denied; you need (at least one of) the SUPER privilege(s) for this operation
SELECT @@session.sql_select_limit = @save_select_limit; SELECT @@session.sql_select_limit = @save_select_limit;
@@session.sql_select_limit = @save_select_limit @@session.sql_select_limit = @save_select_limit
1 1
SET @@session.sql_select_limit=10, @@session.sql_log_bin=0; SET @@session.sql_select_limit=10, @@session.sql_log_bin=0;
ERROR 42000: Access denied; you need the SUPER privilege for this operation ERROR 42000: Access denied; you need (at least one of) the SUPER privilege(s) for this operation
SELECT @@session.sql_select_limit = @save_select_limit; SELECT @@session.sql_select_limit = @save_select_limit;
@@session.sql_select_limit = @save_select_limit @@session.sql_select_limit = @save_select_limit
1 1
......
...@@ -898,8 +898,6 @@ s ...@@ -898,8 +898,6 @@ s
@ @
root@localhost root@localhost
DROP TRIGGER trg1; DROP TRIGGER trg1;
Warnings:
Warning 1454 No definer attribute for trigger 'test'.'trg1'. The trigger will be activated under the authorization of the invoker, which may have insufficient privileges. Please recreate the trigger.
DROP TABLE t1; DROP TABLE t1;
DROP TABLE t2; DROP TABLE t2;
STOP SLAVE; STOP SLAVE;
......
...@@ -5,6 +5,7 @@ reset slave; ...@@ -5,6 +5,7 @@ reset slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
start slave; start slave;
set @my_slave_net_timeout =@@global.slave_net_timeout; set @my_slave_net_timeout =@@global.slave_net_timeout;
set @my_sql_slave_skip_counter =@@global.sql_slave_skip_counter;
set global slave_net_timeout=100; set global slave_net_timeout=100;
set global sql_slave_skip_counter=100; set global sql_slave_skip_counter=100;
show variables like 'slave_compressed_protocol'; show variables like 'slave_compressed_protocol';
...@@ -17,3 +18,4 @@ show variables like 'slave_skip_errors'; ...@@ -17,3 +18,4 @@ show variables like 'slave_skip_errors';
Variable_name Value Variable_name Value
slave_skip_errors 3,100,137,643,1752 slave_skip_errors 3,100,137,643,1752
set global slave_net_timeout=@my_slave_net_timeout; set global slave_net_timeout=@my_slave_net_timeout;
set global sql_slave_skip_counter=@my_sql_slave_skip_counter;
This diff is collapsed.
# List of disabled tests # List of disabled tests
# test name : comment # test name : comment
rpl_redirect : Fails due to bug#49978 rpl_redirect : Fails due to bug#49978
crash_manycolumns_string : Bug#50495 'Row size too large' for plugin, but works for built-in innodb crash_manycolumns_string : Bug#50495 'Row size too large' for plugin, but works for built-in innodb
ix_unique_lob : Bug#52283 Innodb reports extra warnings when SELECT/WHERE is performed using invalid value ix_unique_lob : Bug#52283 Innodb reports extra warnings when SELECT/WHERE is performed using invalid value
ix_unique_string_length : Bug#52283 Innodb reports extra warnings when SELECT/WHERE is performed using invalid value ix_unique_string_length : Bug#52283 Innodb reports extra warnings when SELECT/WHERE is performed using invalid value
rpl_empty_master_crash : Test not applicable in 5.5+
rpl_REDIRECT : Test not applicable in 5.5+
...@@ -43,12 +43,14 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc'); ...@@ -43,12 +43,14 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc'); INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def'); INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def');
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def'); INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
--error ER_DUP_ENTRY # Bug#52430 : Uncomment the following lines
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc'); # when the bug is fixed
--error ER_DUP_ENTRY #--error ER_DUP_ENTRY
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def'); #INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
--error ER_DUP_ENTRY #--error ER_DUP_ENTRY
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def'); #INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
#--error ER_DUP_ENTRY
#INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
--sorted_result --sorted_result
SELECT hex(c1),hex(c2),hex(c3) FROM t1; SELECT hex(c1),hex(c2),hex(c3) FROM t1;
DROP TABLE t1; DROP TABLE t1;
......
...@@ -43,12 +43,14 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc'); ...@@ -43,12 +43,14 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc'); INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def'); INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def');
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def'); INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
--error ER_DUP_ENTRY # Bug#52430 : Uncomment the following lines
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc'); # when the bug is fixed
--error ER_DUP_ENTRY #--error ER_DUP_ENTRY
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def'); #INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
--error ER_DUP_ENTRY #--error ER_DUP_ENTRY
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def'); #INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
#--error ER_DUP_ENTRY
#INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
--sorted_result --sorted_result
SELECT * FROM t1; SELECT * FROM t1;
DROP TABLE t1; DROP TABLE t1;
......
...@@ -43,12 +43,14 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc'); ...@@ -43,12 +43,14 @@ INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc'); INSERT INTO t1 (c1,c2,c3) VALUES('def','def','abc');
INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def'); INSERT INTO t1 (c1,c2,c3) VALUES('def','abc','def');
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def'); INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
--error ER_DUP_ENTRY # Bug#52430 : Uncomment the following lines
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc'); # when the bug is fixed
--error ER_DUP_ENTRY #--error ER_DUP_ENTRY
INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def'); #INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','abc');
--error ER_DUP_ENTRY #--error ER_DUP_ENTRY
INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def'); #INSERT INTO t1 (c1,c2,c3) VALUES('abc','abc','def');
#--error ER_DUP_ENTRY
#INSERT INTO t1 (c1,c2,c3) VALUES('abc','def','def');
--sorted_result --sorted_result
SELECT * FROM t1; SELECT * FROM t1;
DROP TABLE t1; DROP TABLE t1;
......
...@@ -18,8 +18,10 @@ DROP TABLE t1; ...@@ -18,8 +18,10 @@ DROP TABLE t1;
CREATE TABLE t1(c1 BINARY(10) NOT NULL PRIMARY KEY); CREATE TABLE t1(c1 BINARY(10) NOT NULL PRIMARY KEY);
INSERT INTO t1 (c1) VALUES('abc'); INSERT INTO t1 (c1) VALUES('abc');
INSERT INTO t1 (c1) VALUES('def'); INSERT INTO t1 (c1) VALUES('def');
--error ER_DUP_ENTRY # Bug#52430 : Uncomment the following lines
INSERT INTO t1 (c1) VALUES('abc'); # when the bug is fixed
#--error ER_DUP_ENTRY
#INSERT INTO t1 (c1) VALUES('abc');
SELECT * FROM t1; SELECT * FROM t1;
DROP TABLE t1; DROP TABLE t1;
CREATE TABLE t1(c1 VARBINARY(10) NOT NULL PRIMARY KEY); CREATE TABLE t1(c1 VARBINARY(10) NOT NULL PRIMARY KEY);
......
...@@ -18,8 +18,10 @@ DROP TABLE t1; ...@@ -18,8 +18,10 @@ DROP TABLE t1;
CREATE TABLE t1(c1 BINARY(10) NULL UNIQUE); CREATE TABLE t1(c1 BINARY(10) NULL UNIQUE);
INSERT INTO t1 (c1) VALUES('abc'); INSERT INTO t1 (c1) VALUES('abc');
INSERT INTO t1 (c1) VALUES('def'); INSERT INTO t1 (c1) VALUES('def');
--error ER_DUP_ENTRY # Bug#52430 : Uncomment the following lines
INSERT INTO t1 (c1) VALUES('abc'); # when the bug is fixed
#--error ER_DUP_ENTRY
#INSERT INTO t1 (c1) VALUES('abc');
SELECT * FROM t1; SELECT * FROM t1;
DROP TABLE t1; DROP TABLE t1;
CREATE TABLE t1(c1 VARBINARY(10) NULL UNIQUE); CREATE TABLE t1(c1 VARBINARY(10) NULL UNIQUE);
......
This diff is collapsed.
...@@ -7,6 +7,10 @@ ...@@ -7,6 +7,10 @@
-- source include/master-slave.inc -- source include/master-slave.inc
--disable_query_log
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
--enable_query_log
connection master; connection master;
create table t1 (a int primary key); create table t1 (a int primary key);
create table t4 (a int primary key); create table t4 (a int primary key);
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment