mirror of
https://github.com/MariaDB/server.git
synced 2025-12-24 11:21:21 +03:00
Manual merge from mysql-next-mr.
Conflicts: - sql/sql_plugin.cc
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# Copyright (C) 2000-2006 MySQL AB
|
||||
# Copyright (C) 2000-2006 MySQL AB, 2008-2009 Sun Microsystems, Inc.
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Library General Public
|
||||
@@ -75,6 +75,8 @@ EXTRA_DIST = README \
|
||||
|
||||
# List of directories containing test + result files and the
|
||||
# related test data files that should be copied
|
||||
# If you want to add a new suite, please check DEFAULT_SUITES in
|
||||
# mysql-test-run.pl.
|
||||
TEST_DIRS = t r include std_data std_data/parts collections \
|
||||
std_data/ndb_backup50 std_data/ndb_backup51 \
|
||||
std_data/ndb_backup51_data_be std_data/ndb_backup51_data_le \
|
||||
@@ -99,7 +101,10 @@ TEST_DIRS = t r include std_data std_data/parts collections \
|
||||
suite/ndb suite/ndb/t suite/ndb/r \
|
||||
suite/rpl_ndb suite/rpl_ndb/t suite/rpl_ndb/r \
|
||||
suite/parts suite/parts/t suite/parts/r suite/parts/inc \
|
||||
suite/innodb suite/innodb/t suite/innodb/r suite/innodb/include
|
||||
suite/innodb suite/innodb/t suite/innodb/r suite/innodb/include \
|
||||
suite/sys_vars suite/sys_vars/t suite/sys_vars/inc suite/sys_vars/r \
|
||||
suite/perfschema suite/perfschema/t suite/perfschema/r \
|
||||
suite/perfschema/include
|
||||
|
||||
# Used by dist-hook and install-data-local to copy all
|
||||
# test files into either dist or install directory
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=n_mix --vardir=var-n_mix --mysqld=--binlog-format=mixed --suite=main,binlog,innodb,federated,rpl
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=ps_row --vardir=var-ps_row --ps-protocol --mysqld=--binlog-format=row --suite=main,binlog,innodb,federated,rpl
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=embedded --vardir=var-emebbed --embedded --suite=main,binlog,innodb,federated,rpl
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=n_mix --vardir=var-n_mix --mysqld=--binlog-format=mixed --suite=main,binlog,innodb,federated,rpl,sys_vars,perfschema
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=ps_row --vardir=var-ps_row --ps-protocol --mysqld=--binlog-format=row --suite=main,binlog,innodb,federated,rpl,sys_vars,perfschema
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=embedded --vardir=var-emebbed --embedded --suite=main,binlog,innodb,federated,rpl,sys_vars,perfschema
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=rpl_binlog_row --vardir=var-rpl_binlog_row --mysqld=--binlog-format=row --suite=rpl,binlog
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=funcs_1 --vardir=var-funcs_1 --suite=funcs_1
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=n_mix --vardir=var-n_mix --mysqld=--binlog-format=mixed --suite=main,binlog,innodb,federated,rpl
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=ps_row --vardir=var-ps_row --ps-protocol --mysqld=--binlog-format=row --suite=main,binlog,innodb,federated,rpl
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=embedded --vardir=var-emebbed --embedded --suite=main,binlog,innodb,federated,rpl
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=n_mix --vardir=var-n_mix --mysqld=--binlog-format=mixed --suite=main,binlog,innodb,federated,rpl,sys_vars,perfschema
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=ps_row --vardir=var-ps_row --ps-protocol --mysqld=--binlog-format=row --suite=main,binlog,innodb,federated,rpl,sys_vars,perfschema
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=embedded --vardir=var-emebbed --embedded --suite=main,binlog,innodb,federated,rpl,sys_vars,perfschema
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=rpl_binlog_row --vardir=var-rpl_binlog_row --mysqld=--binlog-format=row --suite=rpl,binlog
|
||||
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=funcs_1 --vardir=var-funcs_1 --suite=funcs_1
|
||||
|
||||
@@ -1,300 +0,0 @@
|
||||
################################################################################
|
||||
# Let
|
||||
# - B be begin, C commit and R rollback.
|
||||
# - T a statement that accesses and changes only transactional tables, i.e.
|
||||
# T-tables
|
||||
# - N a statement that accesses and changes only non-transactional tables,
|
||||
# i.e, N-tables.
|
||||
# - M be a mixed statement, i.e. a statement that updates both T- and
|
||||
# N-tables.
|
||||
# - M* be a mixed statement that fails while updating either a T
|
||||
# or N-table.
|
||||
# - N* be a statement that fails while updating a N-table.
|
||||
#
|
||||
# In this test case, when changes are logged as rows either in the RBR or MIXED
|
||||
# modes, we check if a M* statement that happens early in a transaction is
|
||||
# written to the binary log outside the boundaries of the transaction and
|
||||
# wrapped up in a BEGIN/ROLLBACK. This is done to keep the slave consistent with
|
||||
# the master as the rollback will keep the changes on N-tables and undo them on
|
||||
# T-tables. In particular, we expect the following behavior:
|
||||
#
|
||||
# 1. B M* T C would generate in the binlog B M* R B T C.
|
||||
# 2. B M M* C would generate in the binlog B M M* C.
|
||||
# 3. B M* M* T C would generate in the binlog B M* R B M* R B T C.
|
||||
#
|
||||
# SBR is not considered in this test because a failing statement is written to
|
||||
# the binary along with the error code such that a slave executes and rolls it
|
||||
# back, thus undoing the effects on T-tables.
|
||||
#
|
||||
# Note that, in the first case, we are not preserving history from the master as
|
||||
# we are introducing a rollback that never happened. However, this seems to be
|
||||
# more acceptable than making the slave diverge. In the second case, the slave
|
||||
# will diverge as the changes on T-tables that originated from the M statement
|
||||
# are rolled back on the master but not on the slave. Unfortunately, we cannot
|
||||
# simply roll the transaction back as this would undo any uncommitted changes
|
||||
# on T-tables.
|
||||
#
|
||||
# We check two more cases. First, INSERT...SELECT* which produces the following
|
||||
# results:
|
||||
#
|
||||
# 1. B T INSERT M...SELECT* C" with an error in INSERT M...SELECT* generates in
|
||||
# the binlog the following entries: "Nothing".
|
||||
# 2. B INSERT M...SELECT* C" with an error in INSERT M...SELECT* generates in
|
||||
# the binlog the following entries: B INSERT M...SELECT* R.
|
||||
#
|
||||
# Finally, we also check if any N statement that happens early in a transaction
|
||||
# (i.e. before any T or M statement) is written to the binary log outside the
|
||||
# boundaries of the transaction. In particular, we expect the following
|
||||
# behavior:
|
||||
#
|
||||
# 1. B N N T C would generate in the binlog B N C B N C B T C.
|
||||
# 2. B N N T R would generate in the binlog B N C B N C B T R.
|
||||
# 3. B N* N* T C would generate in the binlog B N R B N R B T C.
|
||||
# 4. B N* N* T R would generate in the binlog B N R B N R B T R.
|
||||
# 5. B N N T N T C would generate in the binlog B N C B N C B T N T C.
|
||||
# 6. B N N T N T R would generate in the binlog the B N C B N C B T N T R.
|
||||
#
|
||||
# Such issues do not happen in SBR. In RBR and MBR, a full-fledged fix will be
|
||||
# pushed after the WL#2687.
|
||||
#
|
||||
# Please, remove this test case after pushing WL#2687.
|
||||
################################################################################
|
||||
|
||||
|
||||
--echo ###################################################################################
|
||||
--echo # CONFIGURATION
|
||||
--echo ###################################################################################
|
||||
CREATE TABLE nt_1 (a text, b int PRIMARY KEY) ENGINE = MyISAM;
|
||||
CREATE TABLE nt_2 (a text, b int PRIMARY KEY) ENGINE = MyISAM;
|
||||
CREATE TABLE tt_1 (a text, b int PRIMARY KEY) ENGINE = Innodb;
|
||||
CREATE TABLE tt_2 (a text, b int PRIMARY KEY) ENGINE = Innodb;
|
||||
|
||||
DELIMITER |;
|
||||
|
||||
CREATE TRIGGER tr_i_tt_1_to_nt_1 BEFORE INSERT ON tt_1 FOR EACH ROW
|
||||
BEGIN
|
||||
INSERT INTO nt_1 VALUES (NEW.a, NEW.b);
|
||||
END|
|
||||
|
||||
CREATE TRIGGER tr_i_nt_2_to_tt_2 BEFORE INSERT ON nt_2 FOR EACH ROW
|
||||
BEGIN
|
||||
INSERT INTO tt_2 VALUES (NEW.a, NEW.b);
|
||||
END|
|
||||
|
||||
DELIMITER ;|
|
||||
|
||||
--echo ###################################################################################
|
||||
--echo # CHECK HISTORY IN BINLOG
|
||||
--echo ###################################################################################
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B M* T C" with error in M* generates in the binlog the "B M* R B T C" entries
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
INSERT INTO nt_1 VALUES ("new text 1", 1);
|
||||
BEGIN;
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO tt_1 VALUES (USER(), 2), (USER(), 1);
|
||||
INSERT INTO tt_2 VALUES ("new text 3", 3);
|
||||
COMMIT;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
INSERT INTO tt_2 VALUES ("new text 4", 4);
|
||||
BEGIN;
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO nt_2 VALUES (USER(), 5), (USER(), 4);
|
||||
INSERT INTO tt_2 VALUES ("new text 6", 6);
|
||||
COMMIT;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B M M* T C" with error in M* generates in the binlog the "B M M* T C" entries
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
INSERT INTO nt_1 VALUES ("new text 10", 10);
|
||||
BEGIN;
|
||||
INSERT INTO tt_1 VALUES ("new text 7", 7), ("new text 8", 8);
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO tt_1 VALUES (USER(), 9), (USER(), 10);
|
||||
INSERT INTO tt_2 VALUES ("new text 11", 11);
|
||||
COMMIT;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
INSERT INTO tt_2 VALUES ("new text 15", 15);
|
||||
BEGIN;
|
||||
INSERT INTO nt_2 VALUES ("new text 12", 12), ("new text 13", 13);
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO nt_2 VALUES (USER(), 14), (USER(), 15);
|
||||
INSERT INTO tt_2 VALUES ("new text 16", 16);
|
||||
COMMIT;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B M* M* T C" with error in M* generates in the binlog the "B M* R B M* R B T C" entries
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
INSERT INTO nt_1 VALUES ("new text 18", 18);
|
||||
INSERT INTO nt_1 VALUES ("new text 20", 20);
|
||||
BEGIN;
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO tt_1 VALUES (USER(), 17), (USER(), 18);
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO tt_1 VALUES (USER(), 19), (USER(), 20);
|
||||
INSERT INTO tt_2 VALUES ("new text 21", 21);
|
||||
COMMIT;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
INSERT INTO tt_2 VALUES ("new text 23", 23);
|
||||
INSERT INTO tt_2 VALUES ("new text 25", 25);
|
||||
BEGIN;
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO nt_2 VALUES (USER(), 22), (USER(), 23);
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO nt_2 VALUES (USER(), 24), (USER(), 25);
|
||||
INSERT INTO tt_2 VALUES ("new text 26", 26);
|
||||
COMMIT;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B T INSERT M...SELECT* C" with an error in INSERT M...SELECT* generates
|
||||
--echo *** in the binlog the following entries: "Nothing".
|
||||
--echo *** There is a bug in that will be fixed after WL#2687. Please, check BUG#47175 for further details.
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
TRUNCATE TABLE nt_2;
|
||||
TRUNCATE TABLE tt_2;
|
||||
INSERT INTO tt_2 VALUES ("new text 7", 7);
|
||||
BEGIN;
|
||||
INSERT INTO tt_2 VALUES ("new text 27", 27);
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO nt_2(a, b) SELECT USER(), b FROM nt_1;
|
||||
INSERT INTO tt_2 VALUES ("new text 28", 28);
|
||||
ROLLBACK;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B INSERT M..SELECT* C" with an error in INSERT M...SELECT* generates
|
||||
--echo *** in the binlog the following entries: "B INSERT M..SELECT* R".
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
TRUNCATE TABLE nt_2;
|
||||
TRUNCATE TABLE tt_2;
|
||||
INSERT INTO tt_2 VALUES ("new text 7", 7);
|
||||
BEGIN;
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO nt_2(a, b) SELECT USER(), b FROM nt_1;
|
||||
COMMIT;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B N N T C" generates in the binlog the "B N C B N C B T C" entries
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
TRUNCATE TABLE nt_1;
|
||||
TRUNCATE TABLE tt_2;
|
||||
BEGIN;
|
||||
INSERT INTO nt_1 VALUES (USER(), 1);
|
||||
INSERT INTO nt_1 VALUES (USER(), 2);
|
||||
INSERT INTO tt_2 VALUES (USER(), 3);
|
||||
COMMIT;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B N N T R" generates in the binlog the "B N C B N C B T R" entries
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
BEGIN;
|
||||
INSERT INTO nt_1 VALUES (USER(), 4);
|
||||
INSERT INTO nt_1 VALUES (USER(), 5);
|
||||
INSERT INTO tt_2 VALUES (USER(), 6);
|
||||
ROLLBACK;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B N* N* T C" with error in N* generates in the binlog the "B N R B N R B T C" entries
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
BEGIN;
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO nt_1 VALUES (USER(), 7), (USER(), 1);
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO nt_1 VALUES (USER(), 8), (USER(), 1);
|
||||
INSERT INTO tt_2 VALUES (USER(), 9);
|
||||
COMMIT;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B N* N* T R" with error in N* generates in the binlog the "B N R B N R B T R" entries
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
BEGIN;
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO nt_1 VALUES (USER(), 10), (USER(), 1);
|
||||
--error ER_DUP_ENTRY
|
||||
INSERT INTO nt_1 VALUES (USER(), 11), (USER(), 1);
|
||||
INSERT INTO tt_2 VALUES (USER(), 12);
|
||||
ROLLBACK;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B N N T N T C" generates in the binlog the "B N C B N C B T N T C" entries
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
BEGIN;
|
||||
INSERT INTO nt_1 VALUES (USER(), 13);
|
||||
INSERT INTO nt_1 VALUES (USER(), 14);
|
||||
INSERT INTO tt_2 VALUES (USER(), 15);
|
||||
INSERT INTO nt_1 VALUES (USER(), 16);
|
||||
INSERT INTO tt_2 VALUES (USER(), 17);
|
||||
COMMIT;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo
|
||||
--echo
|
||||
--echo
|
||||
--echo *** "B N N T N T R" generates in the binlog the "B N C B N C B T N T R" entries
|
||||
--echo
|
||||
let $binlog_start= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
BEGIN;
|
||||
INSERT INTO nt_1 VALUES (USER(), 18);
|
||||
INSERT INTO nt_1 VALUES (USER(), 19);
|
||||
INSERT INTO tt_2 VALUES (USER(), 20);
|
||||
INSERT INTO nt_1 VALUES (USER(), 21);
|
||||
INSERT INTO tt_2 VALUES (USER(), 22);
|
||||
ROLLBACK;
|
||||
--source include/show_binlog_events.inc
|
||||
|
||||
--echo ###################################################################################
|
||||
--echo # CLEAN
|
||||
--echo ###################################################################################
|
||||
|
||||
DROP TABLE tt_1;
|
||||
DROP TABLE tt_2;
|
||||
DROP TABLE nt_1;
|
||||
DROP TABLE nt_2;
|
||||
@@ -6,6 +6,8 @@
|
||||
-- source include/have_blackhole.inc
|
||||
-- source include/have_log_bin.inc
|
||||
|
||||
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||
|
||||
# The server need to be started in $MYSQLTEST_VARDIR since it
|
||||
# uses ../../std_data/
|
||||
-- source include/uses_vardir.inc
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
-- source include/have_log_bin.inc
|
||||
-- source include/have_innodb.inc
|
||||
|
||||
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||
|
||||
--disable_warnings
|
||||
drop table if exists t1, t2;
|
||||
@@ -323,23 +324,24 @@ let $MYSQLD_DATADIR= `select @@datadir`;
|
||||
# and does not make slave to stop)
|
||||
if (`select @@binlog_format = 'ROW'`)
|
||||
{
|
||||
--exec $MYSQL_BINLOG --start-position=525 $MYSQLD_DATADIR/master-bin.000001 > $MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output
|
||||
--echo This does not matter in ROW mode as the rolled back changes do not contain transactional changes as these
|
||||
--echo were previously flushed upon committing/rolling back each statement.
|
||||
}
|
||||
|
||||
if (`select @@binlog_format = 'STATEMENT' || @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
--exec $MYSQL_BINLOG --start-position=556 $MYSQLD_DATADIR/master-bin.000001 > $MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output
|
||||
}
|
||||
|
||||
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||
eval select
|
||||
(@a:=load_file("$MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output"))
|
||||
is not null;
|
||||
--replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR
|
||||
eval select
|
||||
@a like "%#%error_code=0%ROLLBACK\\n/*!*/;%ROLLBACK /* added by mysqlbinlog */;%" OR
|
||||
@a like "%#%error_code=0%ROLLBACK\\r\\n/*!*/;%ROLLBACK /* added by mysqlbinlog */;%",
|
||||
@a not like "%#%error_code=%error_code=%";
|
||||
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
|
||||
eval select
|
||||
(@a:=load_file("$MYSQLTEST_VARDIR/tmp/mix_innodb_myisam_binlog.output"))
|
||||
is not null;
|
||||
--replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR
|
||||
eval select
|
||||
@a like "%#%error_code=0%ROLLBACK\\n/*!*/;%ROLLBACK /* added by mysqlbinlog */;%" OR
|
||||
@a like "%#%error_code=0%ROLLBACK\\r\\n/*!*/;%ROLLBACK /* added by mysqlbinlog */;%",
|
||||
@a not like "%#%error_code=%error_code=%";
|
||||
}
|
||||
drop table t1, t2;
|
||||
|
||||
#
|
||||
|
||||
52
mysql-test/extra/rpl_tests/check_type.inc
Normal file
52
mysql-test/extra/rpl_tests/check_type.inc
Normal file
@@ -0,0 +1,52 @@
|
||||
# Helper file to perform one insert of a value into a table with
|
||||
# different types on master and slave. The file will insert the
|
||||
# result into the type_conversions table *on the slave* to get a
|
||||
# summary of failing and succeeding tests.
|
||||
|
||||
# Input:
|
||||
# $source_type Type on the master
|
||||
# $target_type Type on the slave
|
||||
# $source_value Value on the master (inserted into the table)
|
||||
# $target_value Value on the slave (expected value in the table
|
||||
# on the slave)
|
||||
# $can_convert True if conversion shall work, false if it
|
||||
# shall generate an error
|
||||
|
||||
|
||||
connection master;
|
||||
disable_warnings;
|
||||
DROP TABLE IF EXISTS t1;
|
||||
enable_warnings;
|
||||
eval CREATE TABLE t1 (a $source_type);
|
||||
sync_slave_with_master;
|
||||
eval ALTER TABLE t1 MODIFY a $target_type;
|
||||
|
||||
connection master;
|
||||
eval INSERT INTO t1 VALUES($source_value);
|
||||
if ($can_convert) {
|
||||
sync_slave_with_master;
|
||||
eval SELECT a = $target_value into @compare FROM t1;
|
||||
eval INSERT INTO type_conversions SET
|
||||
Source = "$source_type",
|
||||
Target = "$target_type",
|
||||
Flags = @@slave_type_conversions,
|
||||
On_Master = $source_value,
|
||||
Expected = $target_value,
|
||||
Compare = @compare;
|
||||
UPDATE type_conversions
|
||||
SET On_Slave = (SELECT a FROM t1)
|
||||
WHERE TestNo = LAST_INSERT_ID();
|
||||
}
|
||||
if (!$can_convert) {
|
||||
connection slave;
|
||||
wait_for_slave_to_stop;
|
||||
let $error = query_get_value("SHOW SLAVE STATUS", Last_SQL_Error, 1);
|
||||
eval INSERT INTO type_conversions SET
|
||||
Source = "$source_type",
|
||||
Target = "$target_type",
|
||||
Flags = @@slave_type_conversions,
|
||||
On_Master = $source_value,
|
||||
Error = "$error";
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER = 1;
|
||||
START SLAVE;
|
||||
}
|
||||
400
mysql-test/extra/rpl_tests/create_recursive_construct.inc
Normal file
400
mysql-test/extra/rpl_tests/create_recursive_construct.inc
Normal file
@@ -0,0 +1,400 @@
|
||||
# ==== Purpose ====
|
||||
#
|
||||
# Creates a stored routine, stored function, trigger, view, or
|
||||
# prepared statement (commonly referred to as "recursive construct")
|
||||
# that invokes a given unsafe statement.
|
||||
#
|
||||
# Then, it invokes the created recursive construct several times:
|
||||
#
|
||||
# - With SQL_LOG_BIN = 1 and binlog_format = STATEMENT, to verify
|
||||
# that it gives a warning.
|
||||
#
|
||||
# - With SQL_LOG_BIN = 0 and binlog_format = STATEMENT, to verify that
|
||||
# there is no warning and nothing is logged.
|
||||
#
|
||||
# - With SQL_LOG_BIN = 1 and binlog_format = MIXED, to verify that it
|
||||
# writes row events to the binlog.
|
||||
#
|
||||
# - In some cases, the recursive construct can be invoked so that it
|
||||
# has no side-effects but returns a value that may be
|
||||
# nondeterministic. An example is a function that returns UUID().
|
||||
# The function does not have side effects but its a return value
|
||||
# that may differ on slave. Such statements are invoked so that
|
||||
# the return value is discarded (e.g., SELECT func()), with
|
||||
# SQL_LOG_BIN = 1 and binlog_format = STATEMENT. In this case, no
|
||||
# warning should be given and nothing should be written to the
|
||||
# binlog.
|
||||
#
|
||||
# This is an auxiliary file particularly targeted to being used by the
|
||||
# test binlog_unsafe. In this context, the purpose is to check how
|
||||
# warnings for unsafe statements are propagated in recursive
|
||||
# constructs.
|
||||
#
|
||||
# The statement to invoke ("input") is described using mtr variables,
|
||||
# and the resulting recursive construct ("output") is stored in mtr
|
||||
# variables in a similar fashion. To create several levels of nested
|
||||
# recursive constructs, source this file once, then copy the values of
|
||||
# appropriate output variables to the input variables, and then source
|
||||
# this file again.
|
||||
#
|
||||
#
|
||||
# ==== Usage ====
|
||||
#
|
||||
# See binlog_unsafe for an example of how to use this file.
|
||||
#
|
||||
# let $CRC_ARG_level= <level>;
|
||||
# let $CRC_ARG_type= <type>;
|
||||
# let $CRC_ARG_stmt_sidef= <stmt>;
|
||||
# let $CRC_ARG_value= <stmt>;
|
||||
# let $CRC_ARG_sel_retval= <stmt>;
|
||||
# let $CRC_ARG_sel_sidef= <stmt>;
|
||||
# let $CRC_ARG_desc= <desc>;
|
||||
# source extra/rpl_tests/create_recursive_construct.inc;
|
||||
# let $my_stmt_sidef= $CRC_RET_stmt_sidef;
|
||||
# let $my_value= $CRC_RET_value;
|
||||
# let $my_sel_sidef= $CRC_RET_sel_sidef;
|
||||
# let $my_sel_retval= $CRC_RET_sel_retval;
|
||||
# let $my_drop= $CRC_RET_drop;
|
||||
# let $my_is_toplevel= $CRC_RET_top_is_toplevel;
|
||||
# let $my_desc= $CRC_RET_desc;
|
||||
#
|
||||
# $CRC_ARG_* are used as input parameters (arguments) to this file:
|
||||
#
|
||||
# $CRC_ARG_level is the recursion depth: 1 for the innermost
|
||||
# statement created, 2 for a statement that invokes a statement on
|
||||
# level 1, etc.
|
||||
#
|
||||
# $CRC_ARG_type is an integer from 0 to 6, indicating what type of
|
||||
# statement shall be created:
|
||||
# 0 - Create a stored function where the return value depends on
|
||||
# the value of the given statement.
|
||||
# 1 - Create a stored function that invokes the given statement as
|
||||
# a side-effect but may not return a value that depends on it.
|
||||
# 2 - Create a stored routine that invokes the given statement.
|
||||
# 3 - Create a trigger (on table trigger_table_$CRC_ARG_level) that
|
||||
# invokes the given statement.
|
||||
# 4 - Create a view that returns a value that depends on the value
|
||||
# of the given statement.
|
||||
# 5 - Create a view that invokes the given statement but may return
|
||||
# a value that does not depend on it.
|
||||
# 6 - Create a prepared statement that invokes the given statement.
|
||||
#
|
||||
# $CRC_ARG_stmt_sidef is the statement to invoke. It should be a
|
||||
# statement that can be invoked on its own (not sub-statement),
|
||||
# which causes something unsafe to be written to the binlog.
|
||||
#
|
||||
# $CRC_ARG_value is a sub-statement holding the value of the given
|
||||
# statement. Can be empty if the given statement does not have a
|
||||
# value. Typically, this is non-empty if the given statement is a
|
||||
# function call or user variable, but not if it is a stored routine
|
||||
# call, INSERT, SELECT, etc (because none of them has a value).
|
||||
# $CRC_ARG_value is used only when $CRC_ARG_type=6.
|
||||
#
|
||||
# $CRC_ARG_sel_sidef is a SELECT sub-statement that invokes the
|
||||
# statement as a side-effect, but returns a result set that may not
|
||||
# depend on the statement. Can be empty if the statement cannot
|
||||
# produce a result set from a SELECT. $CRC_ARG_sel_sidef is used
|
||||
# only if $CRC_ARG_type=2
|
||||
#
|
||||
# $CRC_ARG_sel_retval is a SELECT sub-statement that does not have
|
||||
# side-effects, but returns a result set that depends on the unsafe
|
||||
# statement. Can be empty if the statement cannot be invoked from a
|
||||
# SELECT. $CRC_ARG_sel_retval is used only if $CRC_ARG_type=3.
|
||||
#
|
||||
# $CRC_ARG_desc is a human-readable description of the statement to
|
||||
# invoke.
|
||||
#
|
||||
# $CRC_RET_* are used as output parameters (return values) of this
|
||||
# file:
|
||||
#
|
||||
# $CRC_RET_stmt_sidef is a statement invoking the resulting recursive
|
||||
# construct.
|
||||
#
|
||||
# $CRC_RET_value is a sub-statement invoking the resulting recursive
|
||||
# construct and returning the value of the recursive construct.
|
||||
# This is the empty string if the resulting recursive construct does
|
||||
# not have a value. In particular, this is non-empty only if
|
||||
# $CRC_ARG_value=7.
|
||||
#
|
||||
# $CRC_RET_sel_sidef is a SELECT sub-statement that invokes the
|
||||
# resulting recursive construct as a side-effect but where the
|
||||
# result set may not depend on the recursive construct. This is the
|
||||
# empty string if the recursive construct cannot be invoked from a
|
||||
# SELECT. In particular, this is non-empty only if $CRC_ARG_value=6
|
||||
# or $CRC_ARG_value=2.
|
||||
#
|
||||
# $CRC_RET_sel_retval is a SELECT sub-statement that does not have
|
||||
# side-effects, but returns a result set depending on the unsafe
|
||||
# statement. This is the empty string if the recursive construct
|
||||
# cannot produce a result set from a SELECT. In particular, this is
|
||||
# non-empty only if $CRC_ARG_value=7 or $CRC_ARG_value=3.
|
||||
#
|
||||
# $CRC_RET_drop is a statement that drops the created object. I.e.,
|
||||
# it is one of 'DROP FUNCTION <func>', 'DROP PROCEDURE <proc>', etc.
|
||||
#
|
||||
# $CRC_RET_top_is_toplevel is 0 normally, or 1 if the resulting
|
||||
# recursive construct can only be called from a top-level statement.
|
||||
# In particular, this is 1 only when $CRC_ARG_value=1, because
|
||||
# prepared statements cannot be invoked from other recursive
|
||||
# constructs.
|
||||
#
|
||||
# $CRC_RET_desc is a text string that describes the invokation of
|
||||
# the recursive construct in a human-readable fashion.
|
||||
#
|
||||
# Assumptions
|
||||
#
|
||||
# Before sourcing this file with $CRC_ARG_level=X, you need to
|
||||
# create three tables: tX, taX and trigger_table_X. These are used
|
||||
# as auxiliary tables.
|
||||
|
||||
|
||||
#--echo debug: >>>>ENTER create_recursive_construct
|
||||
#--echo debug: level=$CRC_ARG_level
|
||||
#--echo debug: type=$CRC_ARG_type
|
||||
#--echo debug: stmt_sidef=$CRC_ARG_stmt_sidef
|
||||
#--echo debug: value=$CRC_ARG_value
|
||||
#--echo debug: sel_retval=$CRC_ARG_sel_retval
|
||||
#--echo debug: sel_sidef=$CRC_ARG_sel_sidef
|
||||
|
||||
--let $CRC_RET_stmt_sidef=
|
||||
--let $CRC_RET_value=
|
||||
--let $CRC_RET_sel_retval=
|
||||
--let $CRC_RET_sel_sidef=
|
||||
--let $CRC_RET_drop=
|
||||
--let $CRC_RET_is_toplevel= 1
|
||||
--let $CRC_RET_desc=
|
||||
--let $CRC_name=
|
||||
--let $CRC_create=
|
||||
|
||||
######## func_retval ########
|
||||
if (`SELECT $CRC_ARG_type = 0 AND '$CRC_ARG_value' != ''`) {
|
||||
# It will be safe to call this function and discard the return
|
||||
# value, but it will be unsafe to use return value (e.g., in
|
||||
# INSERT...SELECT).
|
||||
--let $CRC_name= func_retval_$CRC_ARG_level
|
||||
--let $CRC_create= CREATE FUNCTION $CRC_name() RETURNS VARCHAR(100) BEGIN INSERT INTO ta$CRC_ARG_level VALUES (47); RETURN $CRC_ARG_value; END
|
||||
--let $CRC_RET_stmt_sidef= INSERT INTO t$CRC_ARG_level VALUES ($CRC_name())
|
||||
--let $CRC_RET_value= $CRC_name()
|
||||
--let $CRC_RET_sel_sidef=
|
||||
--let $CRC_RET_sel_retval= SELECT $CRC_name()
|
||||
--let $CRC_RET_drop= DROP FUNCTION $CRC_name
|
||||
--let $CRC_RET_is_toplevel= 0
|
||||
--let $CRC_RET_desc= function $CRC_name returning value from $CRC_ARG_desc
|
||||
}
|
||||
|
||||
######## func_sidef ########
|
||||
if (`SELECT $CRC_ARG_type = 1`) {
|
||||
# It will be unsafe to call func even if you discard return value.
|
||||
--let $CRC_name= func_sidef_$CRC_ARG_level
|
||||
--let $CRC_create= CREATE FUNCTION $CRC_name() RETURNS VARCHAR(100) BEGIN INSERT INTO ta$CRC_ARG_level VALUES (47); $CRC_ARG_stmt_sidef; RETURN 0; END
|
||||
--let $CRC_RET_stmt_sidef= INSERT INTO t$CRC_ARG_level SELECT $CRC_name()
|
||||
--let $CRC_RET_value=
|
||||
--let $CRC_RET_sel_retval=
|
||||
--let $CRC_RET_sel_sidef= SELECT $CRC_name()
|
||||
--let $CRC_RET_drop= DROP FUNCTION $CRC_name
|
||||
--let $CRC_RET_is_toplevel= 0
|
||||
--let $CRC_RET_desc= function $CRC_name invoking $CRC_ARG_desc
|
||||
}
|
||||
|
||||
######## proc ########
|
||||
if (`SELECT $CRC_ARG_type = 2`) {
|
||||
# It will be unsafe to call this procedure.
|
||||
--let $CRC_name= proc_$CRC_ARG_level
|
||||
--let $CRC_create= CREATE PROCEDURE $CRC_name() BEGIN INSERT INTO ta$CRC_ARG_level VALUES (47); $CRC_ARG_stmt_sidef; END
|
||||
--let $CRC_RET_stmt_sidef= CALL $CRC_name()
|
||||
--let $CRC_RET_value=
|
||||
--let $CRC_RET_sel_retval=
|
||||
--let $CRC_RET_sel_sidef=
|
||||
--let $CRC_RET_drop= DROP PROCEDURE $CRC_name
|
||||
--let $CRC_RET_is_toplevel= 0
|
||||
--let $CRC_RET_desc= procedure $CRC_name invoking $CRC_ARG_desc
|
||||
}
|
||||
|
||||
######## trig ########
|
||||
if (`SELECT $CRC_ARG_type = 3`) {
|
||||
# It will be unsafe to invoke this trigger.
|
||||
--let $CRC_name= trig_$CRC_ARG_level
|
||||
--let $CRC_create= CREATE TRIGGER $CRC_name BEFORE INSERT ON trigger_table_$CRC_ARG_level FOR EACH ROW BEGIN INSERT INTO ta$CRC_ARG_level VALUES (47); $CRC_ARG_stmt_sidef; END
|
||||
--let $CRC_RET_stmt_sidef= INSERT INTO trigger_table_$CRC_ARG_level VALUES (1)
|
||||
--let $CRC_RET_value=
|
||||
--let $CRC_RET_sel_retval=
|
||||
--let $CRC_RET_sel_sidef=
|
||||
--let $CRC_RET_drop= DROP TRIGGER $CRC_name
|
||||
--let $CRC_RET_is_toplevel= 0
|
||||
--let $CRC_RET_desc= trigger $CRC_name invoking $CRC_ARG_desc
|
||||
}
|
||||
|
||||
######## view_retval ########
|
||||
if (`SELECT $CRC_ARG_type = 4 AND '$CRC_ARG_sel_retval' != ''`) {
|
||||
# It will be safe to select from this view if you discard the result
|
||||
# set, but unsafe to use result set (e.g., in INSERT..SELECT).
|
||||
--let $CRC_name= view_retval_$CRC_ARG_level
|
||||
--let $CRC_create= CREATE VIEW $CRC_name AS $CRC_ARG_sel_retval
|
||||
--let $CRC_RET_stmt_sidef= INSERT INTO t$CRC_ARG_LEVEL SELECT * FROM $CRC_name
|
||||
--let $CRC_RET_value=
|
||||
--let $CRC_RET_sel_retval= SELECT * FROM $CRC_name
|
||||
--let $CRC_RET_sel_sidef=
|
||||
--let $CRC_RET_drop= DROP VIEW $CRC_name
|
||||
--let $CRC_RET_is_toplevel= 0
|
||||
--let $CRC_RET_desc= view $CRC_name returning value from $CRC_ARG_desc
|
||||
}
|
||||
|
||||
######## view_sidef ########
|
||||
if (`SELECT $CRC_ARG_type = 5 AND '$CRC_ARG_sel_sidef' != ''`) {
|
||||
# It will be unsafe to select from this view, even if you discard
|
||||
# the return value.
|
||||
--let $CRC_name= view_sidef_$CRC_ARG_level
|
||||
--let $CRC_create= CREATE VIEW $CRC_name AS $CRC_ARG_sel_sidef
|
||||
--let $CRC_RET_stmt_sidef= INSERT INTO t$CRC_ARG_level SELECT * FROM $CRC_name
|
||||
--let $CRC_RET_value=
|
||||
--let $CRC_RET_sel_retval=
|
||||
--let $CRC_RET_sel_sidef= SELECT * FROM $CRC_name
|
||||
--let $CRC_RET_drop= DROP VIEW $CRC_name
|
||||
--let $CRC_RET_is_toplevel= 0
|
||||
--let $CRC_RET_desc= view $CRC_name invoking $CRC_ARG_desc
|
||||
}
|
||||
|
||||
######## prep ########
|
||||
if (`SELECT $CRC_ARG_type = 6`) {
|
||||
# It will be unsafe to execute this prepared statement
|
||||
--let $CRC_name= prep_$CRC_ARG_level
|
||||
--let $CRC_create= PREPARE $CRC_name FROM "$CRC_ARG_stmt_sidef"
|
||||
--let $CRC_RET_stmt_sidef= EXECUTE $CRC_name
|
||||
--let $CRC_RET_value=
|
||||
--let $CRC_RET_sel_retval=
|
||||
--let $CRC_RET_sel_sidef=
|
||||
--let $CRC_RET_drop= DROP PREPARE $CRC_name
|
||||
--let $CRC_RET_is_toplevel= 1
|
||||
--let $CRC_RET_desc= prepared statement $CRC_name invoking $CRC_ARG_desc
|
||||
}
|
||||
|
||||
######## no recursive construct: just return the given statement ########
|
||||
if (`SELECT $CRC_ARG_type = 7`) {
|
||||
# CRC_ARG_type=7 is a special case. We just set $CRC_RET_x =
|
||||
# $CRC_ARG_x. This way, the $CRC_ARG_stmt gets executed directly
|
||||
# (below). In binlog_unsafe.test, it is used to invoke the unsafe
|
||||
# statement created in the outermost loop directly, without
|
||||
# enclosing it in a recursive construct.
|
||||
--let $CRC_RET_stmt_sidef= $CRC_ARG_stmt_sidef
|
||||
--let $CRC_RET_value= $CRC_ARG_value
|
||||
--let $CRC_RET_sel_retval= $CRC_ARG_sel_retval
|
||||
--let $CRC_RET_sel_sidef= $CRC_ARG_sel_sidef
|
||||
--let $CRC_RET_drop=
|
||||
--let $CRC_RET_is_toplevel= 1
|
||||
--let $CRC_RET_desc= $CRC_ARG_desc
|
||||
}
|
||||
|
||||
######## execute! ########
|
||||
if (`SELECT '$CRC_RET_stmt_sidef' != ''`) {
|
||||
--echo
|
||||
--echo Invoking $CRC_RET_desc.
|
||||
if (`SELECT '$CRC_create' != ''`) {
|
||||
--eval $CRC_create
|
||||
}
|
||||
|
||||
--echo * binlog_format = STATEMENT: expect $CRC_ARG_expected_number_of_warnings warnings.
|
||||
--eval $CRC_RET_stmt_sidef
|
||||
--let $n_warnings= `SHOW COUNT(*) WARNINGS`
|
||||
if (`SELECT '$n_warnings' != '$CRC_ARG_expected_number_of_warnings'`) {
|
||||
--echo ******** Failure! Expected $CRC_ARG_expected_number_of_warnings warnings, got $n_warnings warnings. ********
|
||||
SHOW WARNINGS;
|
||||
SHOW BINLOG EVENTS;
|
||||
--die Wrong number of warnings.
|
||||
}
|
||||
|
||||
# These queries are run without query log, to make result file more
|
||||
# readable. Debug info is only printed if something abnormal
|
||||
# happens.
|
||||
--disable_query_log
|
||||
|
||||
--echo * SQL_LOG_BIN = 0: expect nothing logged and no warning.
|
||||
SET SQL_LOG_BIN = 0;
|
||||
RESET MASTER;
|
||||
--eval $CRC_RET_stmt_sidef
|
||||
--let $n_warnings= `SHOW COUNT(*) WARNINGS`
|
||||
if (`SELECT '$n_warnings' != '0'`) {
|
||||
--echo ******** Failure! Expected 0 warnings, got $n_warnings warnings. ********
|
||||
SHOW WARNINGS;
|
||||
SHOW BINLOG EVENTS;
|
||||
--die Wrong number of warnings.
|
||||
}
|
||||
--let $binlog_event= query_get_value(SHOW BINLOG EVENTS, Event_type, 2)
|
||||
if (`SELECT '$binlog_event' != 'No such row'`) {
|
||||
--enable_query_log
|
||||
--echo ******** Failure! Something was written to the binlog despite SQL_LOG_BIN=0 ********
|
||||
SHOW BINLOG EVENTS;
|
||||
--die Binlog not empty
|
||||
}
|
||||
SET SQL_LOG_BIN = 1;
|
||||
|
||||
--echo * binlog_format = MIXED: expect row events in binlog and no warning.
|
||||
SET binlog_format = MIXED;
|
||||
RESET MASTER;
|
||||
--eval $CRC_RET_stmt_sidef
|
||||
--let $n_warnings= `SHOW COUNT(*) WARNINGS`
|
||||
if (`SELECT '$n_warnings' != '0'`) {
|
||||
--echo ******** Failure! Expected 0 warnings, got $n_warnings warnings. ********
|
||||
SHOW WARNINGS;
|
||||
SHOW BINLOG EVENTS;
|
||||
--die Warnings printed
|
||||
}
|
||||
# The first event is format_description, the second is
|
||||
# Query_event('BEGIN'), and the third should be our Table_map.
|
||||
--let $event_type= query_get_value(SHOW BINLOG EVENTS, Event_type, 3)
|
||||
if (`SELECT '$event_type' != 'Table_map'`) {
|
||||
--enable_query_log
|
||||
--echo ******** Failure! Event number 3 was a '$event_type', not a 'Table_map'. ********
|
||||
|
||||
# Currently, there is a bug causing some statements to be logged
|
||||
# partially in statement format. Hence, we don't fail here, we
|
||||
# just print the events (masking out nondeterministic components
|
||||
# of the output) and continue. When binloggging works perfectly,
|
||||
# we should instead execute:
|
||||
#--enable_query_log
|
||||
#SHOW BINLOG EVENTS;
|
||||
#--die Wrong events in binlog.
|
||||
|
||||
# Here, we should really source
|
||||
# include/show_binlog_events.inc. But due to BUG#41913, that
|
||||
# doesn't work, and we have to inline the entire file here. Sigh
|
||||
# :-(
|
||||
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR 107 <binlog_start>
|
||||
--replace_column 2 # 4 # 5 #
|
||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/ /file_id=[0-9]+/file_id=#/ /block_len=[0-9]+/block_len=#/
|
||||
--eval SHOW BINLOG EVENTS FROM 107
|
||||
--disable_query_log
|
||||
}
|
||||
SET binlog_format = STATEMENT;
|
||||
|
||||
--enable_query_log
|
||||
}
|
||||
|
||||
# Invoke created object, discarding the return value. This should not
|
||||
# give any warning.
|
||||
if (`SELECT '$CRC_RET_sel_retval' != ''`) {
|
||||
--echo * Invoke statement so that return value is dicarded: expect no warning.
|
||||
--disable_result_log
|
||||
--eval $CRC_RET_sel_retval
|
||||
--enable_result_log
|
||||
|
||||
# Currently, due to a bug, we do get warnings here, so we don't
|
||||
# fail. When the bug is fixed, we should execute the following.
|
||||
|
||||
#--let $n_warnings= `SHOW COUNT(*) WARNINGS`
|
||||
#if (`SELECT '$n_warnings' != '0'`) {
|
||||
# --enable_query_log
|
||||
# --echo Failure! Expected 0 warnings, got $n_warnings warnings.
|
||||
# SHOW WARNINGS;
|
||||
# SHOW BINLOG EVENTS;
|
||||
# --die Wrong number of warnings.
|
||||
#}
|
||||
}
|
||||
|
||||
#--echo debug: <<<<EXIT create_recursive_construct
|
||||
#--echo debug: stmt_sidef=$CRC_RET_stmt_sidef
|
||||
#--echo debug: value=$CRC_RET_value
|
||||
#--echo debug: sel_retval=$CRC_RET_sel_retval
|
||||
#--echo debug: sel_sidef=$CRC_RET_sel_sidef
|
||||
#--echo debug: drop=$CRC_RET_drop
|
||||
#--echo debug: is_toplevel=$CRC_RET_is_toplevel
|
||||
#--echo debug: desc=$CRC_RET_desc
|
||||
@@ -22,13 +22,7 @@
|
||||
#
|
||||
########################################################################################
|
||||
|
||||
########################################################################################
|
||||
# Configuring the environment
|
||||
########################################################################################
|
||||
--source include/have_innodb.inc
|
||||
--source include/master-slave.inc
|
||||
--source include/not_embedded.inc
|
||||
--source include/not_windows.inc
|
||||
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||
|
||||
CREATE TABLE t1(a INT PRIMARY KEY, data VARCHAR(30000)) ENGINE=Innodb;
|
||||
CREATE TABLE t2(a INT PRIMARY KEY, data VARCHAR(30000)) ENGINE=MyIsam;
|
||||
@@ -50,30 +44,18 @@ eval INSERT INTO t1 (a, data) VALUES (1,
|
||||
--enable_query_log
|
||||
|
||||
--echo *** Single statement on non-transactional table ***
|
||||
--echo *** After WL#2687 the difference between STATEMENT/MIXED and ROW will not exist. ***
|
||||
--disable_query_log
|
||||
--disable_warnings
|
||||
if (`SELECT @@binlog_format = 'STATEMENT' || @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
eval INSERT INTO t2 (a, data) VALUES (2,
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
eval INSERT INTO t2 (a, data) VALUES (2,
|
||||
CONCAT($data, $data, $data, $data, $data, $data));
|
||||
--echo Got one of the listed errors
|
||||
}
|
||||
if (`SELECT @@binlog_format = 'ROW'`)
|
||||
{
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
eval INSERT INTO t2 (a, data) VALUES (2,
|
||||
CONCAT($data, $data, $data, $data, $data, $data));
|
||||
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER = 1;
|
||||
START SLAVE SQL_THREAD;
|
||||
--source include/wait_for_slave_sql_to_start.inc
|
||||
}
|
||||
--enable_warnings
|
||||
--enable_query_log
|
||||
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER = 1;
|
||||
START SLAVE SQL_THREAD;
|
||||
--source include/wait_for_slave_sql_to_start.inc
|
||||
|
||||
connection master;
|
||||
|
||||
--disable_query_log
|
||||
@@ -86,7 +68,6 @@ eval INSERT INTO t2 (a, data) VALUES (5, $data);
|
||||
--enable_query_log
|
||||
|
||||
--echo *** Single statement on both transactional and non-transactional tables. ***
|
||||
--echo *** After WL#2687 we will be able to change the order of the tables. ***
|
||||
--disable_query_log
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
eval UPDATE t2, t1 SET t2.data = CONCAT($data, $data, $data, $data),
|
||||
@@ -95,13 +76,25 @@ eval UPDATE t2, t1 SET t2.data = CONCAT($data, $data, $data, $data),
|
||||
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER = 1;
|
||||
|
||||
if (`SELECT @@binlog_format = 'STATEMENT'`)
|
||||
{
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER = 1;
|
||||
}
|
||||
if (`SELECT @@binlog_format = 'ROW' || @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER = 2;
|
||||
}
|
||||
START SLAVE SQL_THREAD;
|
||||
--source include/wait_for_slave_sql_to_start.inc
|
||||
connection master;
|
||||
|
||||
#--echo ########################################################################################
|
||||
#--echo # 2 - BEGIN - IMPLICIT COMMIT by DDL
|
||||
#--echo ########################################################################################
|
||||
let $diff_statement= SELECT * FROM t1;
|
||||
--source include/diff_master_slave.inc
|
||||
|
||||
--echo ########################################################################################
|
||||
--echo # 2 - BEGIN - IMPLICIT COMMIT by DDL
|
||||
--echo ########################################################################################
|
||||
|
||||
connection master;
|
||||
TRUNCATE TABLE t1;
|
||||
@@ -149,14 +142,13 @@ BEGIN;
|
||||
--eval INSERT INTO t1 (a, data) VALUES (21, 's');
|
||||
--enable_query_log
|
||||
|
||||
if (`SELECT @@binlog_format = 'STATEMENT' || @@binlog_format = 'MIXED'`)
|
||||
if (`SELECT @@binlog_format = 'STATEMENT'`)
|
||||
{
|
||||
--disable_query_log
|
||||
CREATE TABLE t4 SELECT * FROM t1;
|
||||
--enable_query_log
|
||||
--echo Got one of the listed errors
|
||||
}
|
||||
if (`SELECT @@binlog_format = 'ROW'`)
|
||||
if (`SELECT @@binlog_format = 'ROW' || @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
--disable_query_log
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
@@ -186,6 +178,17 @@ BEGIN;
|
||||
CREATE TABLE t5 (a int);
|
||||
--enable_query_log
|
||||
|
||||
if (`SELECT @@binlog_format = 'ROW' || @@binlog_format = 'MIXED'` )
|
||||
{
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER = 1;
|
||||
START SLAVE SQL_THREAD;
|
||||
--source include/wait_for_slave_sql_to_start.inc
|
||||
connection master;
|
||||
}
|
||||
|
||||
let $diff_statement= SELECT * FROM t1;
|
||||
--source include/diff_master_slave.inc
|
||||
|
||||
@@ -341,16 +344,30 @@ BEGIN;
|
||||
--eval INSERT INTO t1 (a, data) VALUES (1, $data);
|
||||
--eval INSERT INTO t1 (a, data) VALUES (2, $data);
|
||||
--eval INSERT INTO t2 (a, data) VALUES (3, $data);
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
--eval INSERT INTO t1 (a, data) VALUES (4, $data);
|
||||
if (`SELECT @@binlog_format = 'STATEMENT'`)
|
||||
{
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
--eval INSERT INTO t1 (a, data) VALUES (4, $data);
|
||||
}
|
||||
if (`SELECT @@binlog_format = 'ROW' || @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
--eval INSERT INTO t1 (a, data) VALUES (4, $data);
|
||||
}
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
--eval INSERT INTO t1 (a, data) VALUES (5, $data);
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
--eval INSERT INTO t1 (a, data) VALUES (6, $data);
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
--eval INSERT INTO t1 (a, data) VALUES (7, $data);
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
--eval UPDATE t2 SET data= CONCAT($data, $data);
|
||||
if (`SELECT @@binlog_format = 'STATEMENT'`)
|
||||
{
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
--eval UPDATE t2 SET data= CONCAT($data, $data);
|
||||
}
|
||||
if (`SELECT @@binlog_format = 'ROW' || @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
--eval UPDATE t2 SET data= CONCAT($data, $data);
|
||||
}
|
||||
--eval INSERT INTO t1 (a, data) VALUES (8, 's');
|
||||
--eval INSERT INTO t1 (a, data) VALUES (9, 's');
|
||||
--eval INSERT INTO t2 (a, data) VALUES (10, 's');
|
||||
@@ -363,19 +380,38 @@ BEGIN;
|
||||
--eval INSERT INTO t1 (a, data) VALUES (15, $data);
|
||||
--eval INSERT INTO t1 (a, data) VALUES (16, $data);
|
||||
--eval INSERT INTO t2 (a, data) VALUES (17, $data);
|
||||
if (`SELECT @@binlog_format = 'STATEMENT'`)
|
||||
{
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
--eval INSERT INTO t1 (a, data) VALUES (18, $data);
|
||||
}
|
||||
if (`SELECT @@binlog_format = 'ROW' || @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
--eval INSERT INTO t1 (a, data) VALUES (18, $data);
|
||||
}
|
||||
--error ER_TRANS_CACHE_FULL, ER_ERROR_ON_WRITE
|
||||
--eval INSERT INTO t1 (a, data) VALUES (18, $data);
|
||||
--eval INSERT INTO t1 (a, data) VALUES (19, $data);
|
||||
--enable_query_log
|
||||
COMMIT;
|
||||
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
if (`SELECT @@binlog_format = 'STATEMENT'`)
|
||||
{
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER = 1;
|
||||
START SLAVE SQL_THREAD;
|
||||
--source include/wait_for_slave_sql_to_start.inc
|
||||
connection master;
|
||||
}
|
||||
|
||||
let $diff_statement= SELECT * FROM t1;
|
||||
--source include/diff_master_slave.inc
|
||||
|
||||
--echo ########################################################################################
|
||||
--echo # CLEAN
|
||||
--echo ########################################################################################
|
||||
|
||||
--disable_warnings
|
||||
connection master;
|
||||
DROP TABLE t1;
|
||||
DROP TABLE t2;
|
||||
@@ -384,12 +420,4 @@ DROP TABLE IF EXISTS t4;
|
||||
DROP TABLE IF EXISTS t5;
|
||||
DROP TABLE IF EXISTS t6;
|
||||
DROP PROCEDURE p1;
|
||||
connection slave;
|
||||
DROP TABLE t1;
|
||||
DROP TABLE t2;
|
||||
DROP TABLE t3;
|
||||
DROP TABLE IF EXISTS t4;
|
||||
DROP TABLE IF EXISTS t5;
|
||||
DROP TABLE IF EXISTS t6;
|
||||
DROP PROCEDURE p1;
|
||||
--enable_warnings
|
||||
sync_slave_with_master;
|
||||
@@ -114,9 +114,7 @@ set @@character_set_server=latin5;
|
||||
select @@character_set_server;
|
||||
select @@character_set_server;
|
||||
|
||||
# ONE_SHOT on not charset/collation stuff is not allowed
|
||||
-- error 1382
|
||||
set one_shot max_join_size=10;
|
||||
set one_shot max_join_size=1000000;
|
||||
|
||||
# Test of wrong character set numbers;
|
||||
error 1115;
|
||||
|
||||
@@ -36,6 +36,9 @@ sync_slave_with_master;
|
||||
STOP SLAVE;
|
||||
RESET SLAVE;
|
||||
|
||||
SET @saved_slave_type_conversions = @@slave_type_conversions;
|
||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS = 'ALL_NON_LOSSY';
|
||||
|
||||
eval CREATE TABLE t1 (a INT, b INT PRIMARY KEY, c CHAR(20),
|
||||
d FLOAT DEFAULT '2.00',
|
||||
e CHAR(4) DEFAULT 'TEST')
|
||||
@@ -62,6 +65,8 @@ SELECT * FROM t1 ORDER BY a;
|
||||
sync_slave_with_master;
|
||||
SELECT * FROM t1 ORDER BY a;
|
||||
|
||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS = @saved_slave_type_conversions;
|
||||
|
||||
--echo *** Drop t1 ***
|
||||
connection master;
|
||||
DROP TABLE t1;
|
||||
@@ -97,9 +102,8 @@ SELECT * FROM t2 ORDER BY a;
|
||||
connection slave;
|
||||
START SLAVE;
|
||||
source include/wait_for_slave_sql_to_stop.inc;
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
--let $errno= query_get_value("SHOW SLAVE STATUS", Last_SQL_Errno, 1)
|
||||
--echo Slave failed with Error $errno
|
||||
STOP SLAVE;
|
||||
RESET SLAVE;
|
||||
SELECT * FROM t2 ORDER BY a;
|
||||
@@ -146,13 +150,12 @@ set @b1 = concat(@b1,@b1);
|
||||
INSERT INTO t3 () VALUES(@b1,2,'Kyle, TEX'),(@b1,1,'JOE AUSTIN'),(@b1,4,'QA TESTING');
|
||||
|
||||
--echo ********************************************
|
||||
--echo *** Expect slave to fail with Error 1522 ***
|
||||
--echo *** Expect slave to fail with Error 1677 ***
|
||||
--echo ********************************************
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
--let $errno= query_get_value("SHOW SLAVE STATUS", Last_SQL_Errno, 1)
|
||||
--echo Slave failed with Error $errno
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
|
||||
START SLAVE;
|
||||
|
||||
@@ -191,13 +194,12 @@ INSERT INTO t4 () VALUES(100.22,2,'Kyle, TEX'),(200.26,1,'JOE AUSTIN'),
|
||||
(30000.22,4,'QA TESTING');
|
||||
|
||||
--echo ********************************************
|
||||
--echo *** Expect slave to fail with Error 1522 ***
|
||||
--echo *** Expect slave to fail with Error 1677 ***
|
||||
--echo ********************************************
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
--let $errno= query_get_value("SHOW SLAVE STATUS", Last_SQL_Errno, 1)
|
||||
--echo Slave failed with Error $errno
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
|
||||
START SLAVE;
|
||||
|
||||
@@ -236,13 +238,12 @@ INSERT INTO t5 () VALUES(1,'Kyle',200.23,1,'b1b1',23.00098),
|
||||
(2,'JOE',300.01,0,'b2b2',1.0000009);
|
||||
|
||||
--echo ********************************************
|
||||
--echo *** Expect slave to fail with Error 1522 ***
|
||||
--echo *** Expect slave to fail with Error 1677 ***
|
||||
--echo ********************************************
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
--let $errno= query_get_value("SHOW SLAVE STATUS", Last_SQL_Errno, 1)
|
||||
--echo Slave failed with Error $errno
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
|
||||
START SLAVE;
|
||||
|
||||
@@ -282,13 +283,12 @@ INSERT INTO t6 () VALUES(1,'Kyle',200.23,1),
|
||||
(2,'JOE',300.01,0);
|
||||
|
||||
--echo ********************************************
|
||||
--echo *** Expect slave to fail with Error 1522 ***
|
||||
--echo *** Expect slave to fail with Error 1677 ***
|
||||
--echo ********************************************
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
--let $errno= query_get_value("SHOW SLAVE STATUS", Last_SQL_Errno, 1)
|
||||
--echo Slave failed with Error $errno
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=3;
|
||||
#START SLAVE;
|
||||
|
||||
@@ -491,13 +491,12 @@ set @b1 = concat(@b1,@b1);
|
||||
INSERT INTO t10 () VALUES(1,@b1,'Kyle'),(2,@b1,'JOE'),(3,@b1,'QA');
|
||||
|
||||
--echo ********************************************
|
||||
--echo *** Expect slave to fail with Error 1522 ***
|
||||
--echo *** Expect slave to fail with Error 1677 ***
|
||||
--echo ********************************************
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
--let $errno= query_get_value("SHOW SLAVE STATUS", Last_SQL_Errno, 1)
|
||||
--echo Slave failed with Error $errno
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
|
||||
START SLAVE;
|
||||
|
||||
@@ -515,7 +514,7 @@ sync_slave_with_master;
|
||||
--echo *** Create t11 on slave ***
|
||||
STOP SLAVE;
|
||||
RESET SLAVE;
|
||||
eval CREATE TABLE t11 (a INT KEY, b BLOB, f TEXT,
|
||||
eval CREATE TABLE t11 (a INT KEY, b BLOB, f INT,
|
||||
c CHAR(5) DEFAULT 'test', e INT DEFAULT '1')ENGINE=$engine_type;
|
||||
|
||||
--echo *** Create t11 on Master ***
|
||||
@@ -535,13 +534,12 @@ set @b1 = concat(@b1,@b1);
|
||||
INSERT INTO t11 () VALUES(1,@b1,'Kyle'),(2,@b1,'JOE'),(3,@b1,'QA');
|
||||
|
||||
--echo ********************************************
|
||||
--echo *** Expect slave to fail with Error 1522 ***
|
||||
--echo *** Expect slave to fail with Error 1677 ***
|
||||
--echo ********************************************
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
--let $errno= query_get_value("SHOW SLAVE STATUS", Last_SQL_Errno, 1)
|
||||
--echo Slave failed with Error $errno
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
|
||||
START SLAVE;
|
||||
|
||||
@@ -811,9 +809,8 @@ ALTER TABLE t15 ADD COLUMN c6 INT AFTER c5;
|
||||
--echo ********************************************
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
--let $errno= query_get_value("SHOW SLAVE STATUS", Last_SQL_Errno, 1)
|
||||
--echo Slave failed with Error $errno
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1;
|
||||
START SLAVE;
|
||||
|
||||
@@ -918,13 +915,12 @@ connection master;
|
||||
INSERT INTO t17 () VALUES(9223372036854775807,2,'Kyle, TEX');
|
||||
|
||||
--echo ********************************************
|
||||
--echo *** Expect slave to fail with Error 1522 ***
|
||||
--echo *** Expect slave to fail with Error 1677 ***
|
||||
--echo ********************************************
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_column 1 # 4 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
--query_vertical SHOW SLAVE STATUS
|
||||
--let $errno= query_get_value("SHOW SLAVE STATUS", Last_SQL_Errno, 1)
|
||||
--echo Slave failed with Error $errno
|
||||
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2;
|
||||
START SLAVE;
|
||||
|
||||
|
||||
@@ -20,19 +20,15 @@ rename table t1 to t5, t2 to t1;
|
||||
# first don't write it to the binlog, to test the NO_WRITE_TO_BINLOG keyword.
|
||||
flush no_write_to_binlog tables;
|
||||
# Check that it's not in the binlog.
|
||||
--replace_result $SERVER_VERSION SERVER_VERSION
|
||||
--replace_column 2 # 5 #
|
||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||
eval SHOW BINLOG EVENTS FROM $rename_event_pos ;
|
||||
let $binlog_start= $rename_event_pos;
|
||||
source include/show_binlog_events.inc;
|
||||
# Check that the master is not confused.
|
||||
select * from t3;
|
||||
# This FLUSH should go into the binlog to not confuse the slave.
|
||||
flush tables;
|
||||
# Check that it's in the binlog.
|
||||
--replace_result $SERVER_VERSION SERVER_VERSION
|
||||
--replace_column 2 # 5 #
|
||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||
eval SHOW BINLOG EVENTS FROM $rename_event_pos ;
|
||||
let $binlog_start= $rename_event_pos;
|
||||
source include/show_binlog_events.inc;
|
||||
|
||||
sync_slave_with_master;
|
||||
# Check that the slave is not confused.
|
||||
|
||||
@@ -47,7 +47,6 @@ insert into t1 set b=1;
|
||||
insert into t2 set a=1, b=1;
|
||||
|
||||
set foreign_key_checks=0;
|
||||
set @@session.binlog_format=row;
|
||||
delete from t1;
|
||||
|
||||
--echo must sync w/o a problem (could not with the buggy code)
|
||||
|
||||
656
mysql-test/extra/rpl_tests/rpl_implicit_commit_binlog.test
Normal file
656
mysql-test/extra/rpl_tests/rpl_implicit_commit_binlog.test
Normal file
@@ -0,0 +1,656 @@
|
||||
################################################################################
|
||||
# In this test case, we verify if some DDL statements implicitly commit a
|
||||
# transaction and are written directly to the binary log without going
|
||||
# through either the Statement- or Transactional-Cache.
|
||||
#
|
||||
# As any statement that goes through a cache is written to the binary log
|
||||
# wrapped in a BEGIN...COMMIT, we proceed as follows:
|
||||
#
|
||||
# - create a transaction and insert some values into a transactional table.
|
||||
# - execute a DDL statement that is supposed to implicitly commit the previous
|
||||
# transaction.
|
||||
# - Check in the binary log for a COMMIT mark which is supposed to be written
|
||||
# before the DDL statement.
|
||||
# - Check in the binary log if the DDL is not wrapped by a BEGIN..COMMIT.
|
||||
#
|
||||
# For further details, please, read WL#2687 and WL#5072.
|
||||
################################################################################
|
||||
|
||||
--echo #########################################################################
|
||||
--echo # CONFIGURATION
|
||||
--echo #########################################################################
|
||||
connection master;
|
||||
|
||||
eval CREATE TABLE tt_1 (ddl_case INT, PRIMARY KEY(ddl_case)) ENGINE = $engine;
|
||||
eval CREATE TABLE tt_2 (ddl_case INT, PRIMARY KEY(ddl_case)) ENGINE = $engine;
|
||||
eval CREATE TABLE nt_1 (ddl_case INT, PRIMARY KEY(ddl_case)) ENGINE = MyIsam;
|
||||
|
||||
INSERT INTO tt_1(ddl_case) VALUES(0);
|
||||
INSERT INTO tt_2(ddl_case) VALUES(0);
|
||||
|
||||
--echo #########################################################################
|
||||
--echo # CHECK IMPLICT COMMIT
|
||||
--echo #########################################################################
|
||||
SET AUTOCOMMIT= 0;
|
||||
let $ddl_cases= 41;
|
||||
while (`SELECT $ddl_cases >= 1`)
|
||||
{
|
||||
--echo -b-b-b-b-b-b-b-b-b-b-b- >> << -b-b-b-b-b-b-b-b-b-b-b-
|
||||
let $in_temporary= "no";
|
||||
let $ok= "yes";
|
||||
#
|
||||
# In SBR and MIXED modes, the commit event is usually the third event in the
|
||||
# binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: INSERT
|
||||
# 3: COMMIT
|
||||
# 4: DDL EVENT which triggered the previous commmit.
|
||||
#
|
||||
if (`select @@binlog_format = 'STATEMENT' || @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
let $commit_event_row_number= 3;
|
||||
}
|
||||
#
|
||||
# In RBR mode, the commit event is usually the fourth event in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: ROW EVENT
|
||||
# 4: COMMIT
|
||||
# 5: DDL EVENT which triggered the previous commmit.
|
||||
#
|
||||
if (`select @@binlog_format = 'ROW'`)
|
||||
{
|
||||
let $commit_event_row_number= 4;
|
||||
}
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is usually the seventh event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: COMMAND
|
||||
# 2: BEGIN
|
||||
# 3: TABLE MAP EVENT
|
||||
# 4: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 5: ROW EVENT
|
||||
# 6: ROW EVENT
|
||||
# 7: COMMIT
|
||||
#
|
||||
if (`select '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 7;
|
||||
}
|
||||
|
||||
let $first_binlog_position= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
--enable_query_log
|
||||
eval INSERT INTO tt_1(ddl_case) VALUES ($ddl_cases);
|
||||
if (`SELECT $ddl_cases = 41`)
|
||||
{
|
||||
let $cmd= LOAD INDEX INTO CACHE nt_1 IGNORE LEAVES;
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
# This seems to be related to epochs.
|
||||
# We need to check this against an updated version or avoid it.
|
||||
let $ok= "no";
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 40`)
|
||||
{
|
||||
let $cmd= LOAD INDEX INTO CACHE tt_1, tt_2 IGNORE LEAVES;
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 39`)
|
||||
{
|
||||
let $cmd= ANALYZE TABLE nt_1;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 38`)
|
||||
{
|
||||
let $cmd= CHECK TABLE nt_1;
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 37`)
|
||||
{
|
||||
let $cmd= OPTIMIZE TABLE nt_1;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 36`)
|
||||
{
|
||||
let $cmd= REPAIR TABLE nt_1;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 35`)
|
||||
{
|
||||
let $cmd= LOCK TABLES tt_1 WRITE;
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 34`)
|
||||
{
|
||||
let $cmd= UNLOCK TABLES;
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 33`)
|
||||
{
|
||||
let $cmd= CREATE USER 'user'@'localhost';
|
||||
}
|
||||
if (`SELECT $ddl_cases = 32`)
|
||||
{
|
||||
let $cmd= GRANT ALL ON *.* TO 'user'@'localhost';
|
||||
}
|
||||
if (`SELECT $ddl_cases = 31`)
|
||||
{
|
||||
let $cmd= SET PASSWORD FOR 'user'@'localhost' = PASSWORD('newpass');
|
||||
#
|
||||
# In NDB (RBR mode), the commit event is the eleventh event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: DDL EVENT which triggered the previous commmit.
|
||||
# 2: BEGIN
|
||||
# 3: TABLE MAP EVENT
|
||||
# 4: ROW EVENT
|
||||
# 5: COMMIT
|
||||
# 6: BEGIN
|
||||
# 7: TABLE MAP EVENT
|
||||
# 8: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 9: ROW EVENT
|
||||
# 10: ROW EVENT
|
||||
# 11: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB' && @@binlog_format = 'ROW'`)
|
||||
{
|
||||
let $commit_event_row_number= 11;
|
||||
}
|
||||
#
|
||||
# In NDB (MIXED mode), the commit event is the eighth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: DDL EVENT which triggered the previous commmit.
|
||||
# 2: COMMIT
|
||||
# 3: BEGIN
|
||||
# 4: TABLE MAP EVENT
|
||||
# 5: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 6: ROW EVENT
|
||||
# 7: ROW EVENT
|
||||
# 8: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB' && @@binlog_format != 'ROW'`)
|
||||
{
|
||||
let $commit_event_row_number= 7;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 30`)
|
||||
{
|
||||
let $cmd= REVOKE ALL PRIVILEGES, GRANT OPTION FROM 'user'@'localhost';
|
||||
}
|
||||
if (`SELECT $ddl_cases = 29`)
|
||||
{
|
||||
let $cmd= RENAME USER 'user'@'localhost' TO 'user_new'@'localhost';
|
||||
}
|
||||
if (`SELECT $ddl_cases = 28`)
|
||||
{
|
||||
let $cmd= DROP USER 'user_new'@'localhost';
|
||||
}
|
||||
if (`SELECT $ddl_cases = 27`)
|
||||
{
|
||||
let $cmd= CREATE EVENT evt ON SCHEDULE AT CURRENT_TIMESTAMP + INTERVAL 1 HOUR DO SELECT * FROM tt_1;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 26`)
|
||||
{
|
||||
let $cmd= ALTER EVENT evt COMMENT 'evt';
|
||||
}
|
||||
if (`SELECT $ddl_cases = 25`)
|
||||
{
|
||||
let $cmd= DROP EVENT evt;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 24`)
|
||||
{
|
||||
let $cmd= CREATE TRIGGER tr AFTER INSERT ON tt_1 FOR EACH ROW UPDATE tt_2 SET ddl_case = ddl_case WHERE ddl_case= NEW.ddl_case;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 23`)
|
||||
{
|
||||
let $cmd= DROP TRIGGER tr;
|
||||
#
|
||||
# In RBR mode, due to the trigger the tt_2 is also updated:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT
|
||||
# 4: ROW EVENT
|
||||
# 5: COMMIT
|
||||
# 6: DDL EVENT which triggered the previous commmit.
|
||||
#
|
||||
if (`select @@binlog_format = 'ROW' && '$engine' != 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 5;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 22`)
|
||||
{
|
||||
let $cmd= CREATE FUNCTION fc () RETURNS VARCHAR(64) RETURN "fc";
|
||||
}
|
||||
if (`SELECT $ddl_cases = 21`)
|
||||
{
|
||||
let $cmd= ALTER FUNCTION fc COMMENT 'fc';
|
||||
}
|
||||
if (`SELECT $ddl_cases = 20`)
|
||||
{
|
||||
let $cmd= DROP FUNCTION fc;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 19`)
|
||||
{
|
||||
let $cmd= CREATE PROCEDURE pc () UPDATE tt_2 SET ddl_case = ddl_case WHERE ddl_case= NEW.ddl_case;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 18`)
|
||||
{
|
||||
let $cmd= ALTER PROCEDURE pc COMMENT 'pc';
|
||||
}
|
||||
if (`SELECT $ddl_cases = 17`)
|
||||
{
|
||||
let $cmd= DROP PROCEDURE pc;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 16`)
|
||||
{
|
||||
let $cmd= CREATE VIEW v AS SELECT * FROM tt_1;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 15`)
|
||||
{
|
||||
let $cmd= ALTER VIEW v AS SELECT * FROM tt_1;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 14`)
|
||||
{
|
||||
let $cmd= DROP VIEW v;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 13`)
|
||||
{
|
||||
let $cmd= CREATE INDEX ix ON tt_1(ddl_case);
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
# 7: DDL EVENT which triggered the previous commmit.
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 12`)
|
||||
{
|
||||
let $cmd= DROP INDEX ix ON tt_1;
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
# 7: DDL EVENT which triggered the previous commmit.
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 11`)
|
||||
{
|
||||
let $cmd= CREATE TEMPORARY TABLE tt_xx (a int);
|
||||
let $in_temporary= "yes";
|
||||
# In SBR and MIXED modes, the DDL statement is written to the binary log but
|
||||
# does not commit the current transaction.
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: INSERT
|
||||
# 3: CREATE TEMPORARY
|
||||
#
|
||||
# In RBR the transaction is not committed either and the statement is not
|
||||
# written to the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: ROW EVENT
|
||||
#
|
||||
if (`select @@binlog_format = 'STATEMENT' || @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
let $commit_event_row_number= 4;
|
||||
}
|
||||
#
|
||||
# In NDB (RBR mode), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB' && @@binlog_format = 'ROW'` )
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
#
|
||||
# In NDB (MIXED mode), the commit event is the nineth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: DDL EVENT which triggered the previous commmit.
|
||||
# 3: COMMIT
|
||||
# 4: BEGIN
|
||||
# 5: TABLE MAP EVENT
|
||||
# 6: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 7: ROW EVENT
|
||||
# 8: ROW EVENT
|
||||
# 9: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB' && @@binlog_format != 'ROW'` )
|
||||
{
|
||||
let $commit_event_row_number= 9;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 10`)
|
||||
{
|
||||
let $cmd= ALTER TABLE tt_xx ADD COLUMN (b int);
|
||||
#
|
||||
# In MIXED mode, the changes are logged as rows and we have what follows:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: ROW EVENT
|
||||
# 4: COMMIT
|
||||
# 5: DDL EVENT which triggered the previous commmit.
|
||||
#
|
||||
if (`select @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
let $commit_event_row_number= 4;
|
||||
}
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 9`)
|
||||
{
|
||||
let $cmd= ALTER TABLE tt_xx RENAME new_tt_xx;
|
||||
#
|
||||
# In MIXED mode, the changes are logged as rows and we have what follows:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: ROW EVENT
|
||||
# 4: COMMIT
|
||||
# 5: DDL EVENT which triggered the previous commmit.
|
||||
#
|
||||
if (`select @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
let $commit_event_row_number= 4;
|
||||
}
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 8`)
|
||||
{
|
||||
let $cmd= DROP TEMPORARY TABLE IF EXISTS new_tt_xx;
|
||||
let $in_temporary= "yes";
|
||||
#
|
||||
# In SBR and MIXED modes, the DDL statement is written to the binary log
|
||||
# but does not commit the current transaction:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: INSERT
|
||||
# 3: DROP TEMPORARY
|
||||
#
|
||||
# In RBR the transaction is not committed either and the statement is not
|
||||
# written to the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: ROW EVENT
|
||||
#
|
||||
if (`select @@binlog_format = 'STATEMENT'`)
|
||||
{
|
||||
let $commit_event_row_number= 4;
|
||||
}
|
||||
# In MIXED mode, the changes are logged as rows and we have what follows:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: ROW EVENT
|
||||
# 4: DROP TEMPORARY table IF EXISTS
|
||||
#
|
||||
if (`select @@binlog_format = 'MIXED'`)
|
||||
{
|
||||
let $commit_event_row_number= 5;
|
||||
}
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
#
|
||||
# In NDB (MIXED mode), the commit event is the nineth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: DDL EVENT which triggered the previous commmit.
|
||||
# 3: COMMIT
|
||||
# 4: BEGIN
|
||||
# 5: TABLE MAP EVENT
|
||||
# 6: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 7: ROW EVENT
|
||||
# 8: ROW EVENT
|
||||
# 9: COMMIT
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB' && @@binlog_format != 'ROW'` )
|
||||
{
|
||||
let $commit_event_row_number= 9;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 7`)
|
||||
{
|
||||
let $cmd= CREATE TABLE tt_xx (a int);
|
||||
}
|
||||
if (`SELECT $ddl_cases = 6`)
|
||||
{
|
||||
let $cmd= ALTER TABLE tt_xx ADD COLUMN (b int);
|
||||
}
|
||||
if (`SELECT $ddl_cases = 5`)
|
||||
{
|
||||
let $cmd= RENAME TABLE tt_xx TO new_tt_xx;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 4`)
|
||||
{
|
||||
let $cmd= TRUNCATE TABLE new_tt_xx;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 3`)
|
||||
{
|
||||
let $cmd= DROP TABLE IF EXISTS tt_xx, new_tt_xx;
|
||||
}
|
||||
if (`SELECT $ddl_cases = 2`)
|
||||
{
|
||||
let $cmd= CREATE DATABASE db;
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
# 7: DDL EVENT which triggered the previous commmit.
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
if (`SELECT $ddl_cases = 1`)
|
||||
{
|
||||
let $cmd= DROP DATABASE IF EXISTS db;
|
||||
#
|
||||
# In NDB (RBR and MIXED modes), the commit event is the sixth event
|
||||
# in the binary log:
|
||||
#
|
||||
# 1: BEGIN
|
||||
# 2: TABLE MAP EVENT
|
||||
# 3: TABLE MAP EVENT (ndb_apply_status)
|
||||
# 4: ROW EVENT
|
||||
# 5: ROW EVENT
|
||||
# 6: COMMIT
|
||||
# 7: DDL EVENT which triggered the previous commmit.
|
||||
#
|
||||
if (`SELECT '$engine' = 'NDB'`)
|
||||
{
|
||||
let $commit_event_row_number= 6;
|
||||
}
|
||||
}
|
||||
--eval $cmd
|
||||
--disable_query_log
|
||||
#
|
||||
# When a temporary table is either created or dropped, there is no implicit
|
||||
# commit. The flag in_temporary is used to avoid aborting the test in such
|
||||
# cases. Thus we force the commit.
|
||||
#
|
||||
if (`SELECT $in_temporary = "yes"`)
|
||||
{
|
||||
--eval COMMIT
|
||||
}
|
||||
let $event_commit= query_get_value("SHOW BINLOG EVENTS FROM $first_binlog_position", Info, $commit_event_row_number);
|
||||
if (`SELECT SUBSTRING("$event_commit",1,6) != "COMMIT"`)
|
||||
{
|
||||
if (`SELECT $ok = "yes"`)
|
||||
{
|
||||
--echo it *does not* commit the current transaction.
|
||||
--echo $cmd
|
||||
--echo $event_commit
|
||||
SHOW BINLOG EVENTS;
|
||||
exit;
|
||||
}
|
||||
}
|
||||
--echo -e-e-e-e-e-e-e-e-e-e-e- >> << -e-e-e-e-e-e-e-e-e-e-e-
|
||||
let $binlog_start= $first_binlog_position;
|
||||
--echo -b-b-b-b-b-b-b-b-b-b-b- >> << -b-b-b-b-b-b-b-b-b-b-b-
|
||||
--source include/show_binlog_events.inc
|
||||
--echo -e-e-e-e-e-e-e-e-e-e-e- >> << -e-e-e-e-e-e-e-e-e-e-e-
|
||||
--echo
|
||||
dec $ddl_cases;
|
||||
}
|
||||
SET AUTOCOMMIT= 1;
|
||||
|
||||
--echo ###################################################################################
|
||||
--echo # CHECK CONSISTENCY
|
||||
--echo ###################################################################################
|
||||
--sync_slave_with_master
|
||||
|
||||
--let $diff_table_1= master:test.tt_1
|
||||
--let $diff_table_2= slave:test.tt_1
|
||||
--source include/diff_tables.inc
|
||||
|
||||
--echo ###################################################################################
|
||||
--echo # CLEAN
|
||||
--echo ###################################################################################
|
||||
connection master;
|
||||
|
||||
DROP TABLE tt_1;
|
||||
DROP TABLE tt_2;
|
||||
DROP TABLE nt_1;
|
||||
|
||||
sync_slave_with_master;
|
||||
@@ -1,9 +1,3 @@
|
||||
# File for specialities regarding replication from or to InnoDB
|
||||
# tables.
|
||||
|
||||
source include/master-slave.inc;
|
||||
source include/have_innodb.inc;
|
||||
|
||||
#
|
||||
# Bug#11401: Load data infile 'REPLACE INTO' fails on slave.
|
||||
#
|
||||
@@ -76,7 +70,7 @@ sync_slave_with_master;
|
||||
connection slave;
|
||||
|
||||
# We want to verify that the following transactions are written to the
|
||||
# binlog, despite the transaction is rolled back. (The should be
|
||||
# binlog, despite the transaction is rolled back. (They should be
|
||||
# written to the binlog since they contain non-transactional DROP
|
||||
# TEMPORARY TABLE). To see that, we use the auxiliary table t1, which
|
||||
# is transactional (InnoDB) on master and MyISAM on slave. t1 should
|
||||
@@ -84,6 +78,10 @@ connection slave;
|
||||
# the transaction to be logged. Since t1 is non-transactional on
|
||||
# slave, the change will not be rolled back, so the inserted rows will
|
||||
# stay in t1 and we can verify that the transaction was replicated.
|
||||
#
|
||||
# Note, however, that the previous explanation is not true for ROW and
|
||||
# MIXED modes as rollback on a transactional table is not written to
|
||||
# the binary log.
|
||||
ALTER TABLE mysqltest1.t1 ENGINE = MyISAM;
|
||||
SHOW CREATE TABLE mysqltest1.t1;
|
||||
|
||||
@@ -38,18 +38,19 @@ connection master;
|
||||
truncate table t1;
|
||||
# first scenario: duplicate on first row
|
||||
insert delayed into t1 values(10, "my name");
|
||||
if ($binlog_format_statement)
|
||||
flush table t1;
|
||||
if (`SELECT @@global.binlog_format = 'STATEMENT'`)
|
||||
{
|
||||
# statement below will be converted to non-delayed INSERT and so
|
||||
# will stop at first error, guaranteeing replication.
|
||||
--error ER_DUP_ENTRY
|
||||
insert delayed into t1 values(10, "is Bond"), (20, "James Bond");
|
||||
}
|
||||
if (!$binlog_format_statement)
|
||||
if (`SELECT @@global.binlog_format != 'STATEMENT'`)
|
||||
{
|
||||
insert delayed into t1 values(10, "is Bond"), (20, "James Bond");
|
||||
}
|
||||
flush table t1; # to wait for INSERT DELAYED to be done
|
||||
flush table t1;
|
||||
select * from t1;
|
||||
sync_slave_with_master;
|
||||
# when bug existed in statement-based binlogging, t1 on slave had
|
||||
@@ -59,7 +60,7 @@ select * from t1;
|
||||
# second scenario: duplicate on second row
|
||||
connection master;
|
||||
delete from t1 where id!=10;
|
||||
if ($binlog_format_statement)
|
||||
if (`SELECT @@global.binlog_format = 'STATEMENT'`)
|
||||
{
|
||||
# statement below will be converted to non-delayed INSERT and so
|
||||
# will be binlogged with its ER_DUP_ENTRY error code, guaranteeing
|
||||
@@ -67,7 +68,7 @@ if ($binlog_format_statement)
|
||||
--error ER_DUP_ENTRY
|
||||
insert delayed into t1 values(20, "is Bond"), (10, "James Bond");
|
||||
}
|
||||
if (!$binlog_format_statement)
|
||||
if (`SELECT @@global.binlog_format != 'STATEMENT'`)
|
||||
{
|
||||
insert delayed into t1 values(20, "is Bond"), (10, "James Bond");
|
||||
}
|
||||
@@ -108,6 +109,7 @@ if (`SELECT @@global.binlog_format != 'ROW'`)
|
||||
{
|
||||
#must show two INSERT DELAYED
|
||||
--replace_column 1 x 2 x 3 x 4 x 5 x
|
||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||
show binlog events in 'master-bin.000002' LIMIT 2,2;
|
||||
}
|
||||
select * from t1;
|
||||
@@ -118,6 +120,7 @@ if (`SELECT @@global.binlog_format != 'ROW'`)
|
||||
{
|
||||
#must show two INSERT DELAYED
|
||||
--replace_column 1 x 2 x 3 x 4 x 5 x
|
||||
--replace_regex /table_id: [0-9]+/table_id: #/
|
||||
show binlog events in 'slave-bin.000002' LIMIT 2,2;
|
||||
}
|
||||
select * from t1;
|
||||
|
||||
@@ -9,6 +9,8 @@
|
||||
# column and index but without primary key.
|
||||
##############################################################
|
||||
|
||||
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||
|
||||
--echo #
|
||||
--echo # Setup
|
||||
--echo #
|
||||
@@ -188,7 +190,9 @@ drop trigger t1_bi;
|
||||
|
||||
# Check that nested call doesn't affect outer context.
|
||||
select last_insert_id();
|
||||
--disable_warnings
|
||||
select bug15728_insert();
|
||||
--enable_warnings
|
||||
select last_insert_id();
|
||||
insert into t1 (last_id) values (bug15728());
|
||||
# This should be exactly one greater than in the previous call.
|
||||
@@ -441,7 +445,9 @@ delimiter ;|
|
||||
|
||||
INSERT INTO t1 VALUES (NULL, -1);
|
||||
CALL p1();
|
||||
--disable_warnings
|
||||
SELECT f1();
|
||||
--enable_warnings
|
||||
INSERT INTO t1 VALUES (NULL, f2()), (NULL, LAST_INSERT_ID()),
|
||||
(NULL, LAST_INSERT_ID()), (NULL, f2()), (NULL, f2());
|
||||
INSERT INTO t1 VALUES (NULL, f2());
|
||||
@@ -510,7 +516,9 @@ insert into t2 (id) values(1),(2),(3);
|
||||
delete from t2;
|
||||
set sql_log_bin=1;
|
||||
#inside SELECT, then inside INSERT
|
||||
--disable_warnings
|
||||
select insid();
|
||||
--enable_warnings
|
||||
set sql_log_bin=0;
|
||||
insert into t2 (id) values(5),(6),(7);
|
||||
delete from t2 where id>=5;
|
||||
|
||||
@@ -55,7 +55,9 @@ INSERT INTO t1 VALUES (2, 2);
|
||||
INSERT INTO t1 VALUES (3, 3);
|
||||
INSERT INTO t1 VALUES (4, 4);
|
||||
|
||||
--disable_warnings
|
||||
INSERT IGNORE INTO t1 SELECT NULL, t2.b FROM t2 ORDER BY t2.a;
|
||||
--enable_warnings
|
||||
|
||||
SELECT * FROM t1 ORDER BY a;
|
||||
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
# Requires statement logging
|
||||
-- source include/have_binlog_format_mixed_or_statement.inc
|
||||
|
||||
# See if replication of a "LOAD DATA in an autoincrement column"
|
||||
# Honours autoincrement values
|
||||
# i.e. if the master and slave have the same sequence
|
||||
@@ -163,8 +160,11 @@ eval $lower_stmt_head infile '../../std_data/rpl_loaddata2.dat' into table t2 fi
|
||||
terminated by ',' optionally enclosed by '%' escaped by '@' lines terminated by
|
||||
'\n##\n' starting by '>' ignore 1 lines;
|
||||
connection slave;
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
drop table t1, t2;
|
||||
if (`SELECT @@global.binlog_format != 'ROW'`)
|
||||
{
|
||||
--source include/wait_for_slave_sql_to_stop.inc
|
||||
drop table t1, t2;
|
||||
}
|
||||
connection master;
|
||||
drop table t1, t2;
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ show binlog events from 107 limit 1;
|
||||
show binlog events from 107 limit 2;
|
||||
--replace_column 2 # 5 #
|
||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
||||
show binlog events from 107 limit 2,1;
|
||||
show binlog events from 107 limit 1,4;
|
||||
flush logs;
|
||||
|
||||
# We need an extra update before doing save_master_pos.
|
||||
@@ -104,7 +104,7 @@ show binlog events in 'slave-bin.000001' from 4;
|
||||
--replace_column 2 # 5 #
|
||||
--replace_regex /\/\* xid=.* \*\//\/* XID *\// /table_id: [0-9]+/table_id: #/
|
||||
show binlog events in 'slave-bin.000002' from 4;
|
||||
source include/show_slave_status.inc;
|
||||
source include/show_slave_status2.inc;
|
||||
|
||||
# Need to recode the following
|
||||
|
||||
|
||||
554
mysql-test/extra/rpl_tests/rpl_mixing_engines.inc
Normal file
554
mysql-test/extra/rpl_tests/rpl_mixing_engines.inc
Normal file
@@ -0,0 +1,554 @@
|
||||
################################################################################
|
||||
# This is an auxiliary file used by rpl_mixing_engines.test, and that it
|
||||
# executes SQL statements according to a format string, as specified in
|
||||
# rpl_mixing_engines.test. In addition, it accepts the special format
|
||||
# strings 'configure' and 'clean', used before and after everything else.
|
||||
################################################################################
|
||||
|
||||
if (`SELECT HEX(@commands) = HEX('configure')`)
|
||||
{
|
||||
connection master;
|
||||
|
||||
SET SQL_LOG_BIN=0;
|
||||
eval CREATE TABLE nt_1 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE nt_2 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE nt_3 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE nt_4 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE nt_5 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE nt_6 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE tt_1 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval CREATE TABLE tt_2 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval CREATE TABLE tt_3 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval CREATE TABLE tt_4 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval CREATE TABLE tt_5 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval CREATE TABLE tt_6 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval SET SQL_LOG_BIN=1;
|
||||
|
||||
connection slave;
|
||||
|
||||
SET SQL_LOG_BIN=0;
|
||||
eval CREATE TABLE nt_1 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE nt_2 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE nt_3 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE nt_4 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE nt_5 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE nt_6 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = MyISAM;
|
||||
eval CREATE TABLE tt_1 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval CREATE TABLE tt_2 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval CREATE TABLE tt_3 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval CREATE TABLE tt_4 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval CREATE TABLE tt_5 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
eval CREATE TABLE tt_6 (trans_id INT, stmt_id INT, info VARCHAR(64), PRIMARY KEY(trans_id, stmt_id)) ENGINE = $engine_type;
|
||||
SET SQL_LOG_BIN=1;
|
||||
|
||||
connection master;
|
||||
|
||||
INSERT INTO nt_1(trans_id, stmt_id) VALUES(1,1);
|
||||
INSERT INTO nt_2(trans_id, stmt_id) VALUES(1,1);
|
||||
INSERT INTO nt_3(trans_id, stmt_id) VALUES(1,1);
|
||||
INSERT INTO nt_4(trans_id, stmt_id) VALUES(1,1);
|
||||
INSERT INTO nt_5(trans_id, stmt_id) VALUES(1,1);
|
||||
INSERT INTO nt_6(trans_id, stmt_id) VALUES(1,1);
|
||||
|
||||
INSERT INTO tt_1(trans_id, stmt_id) VALUES(1,1);
|
||||
INSERT INTO tt_2(trans_id, stmt_id) VALUES(1,1);
|
||||
INSERT INTO tt_3(trans_id, stmt_id) VALUES(1,1);
|
||||
INSERT INTO tt_4(trans_id, stmt_id) VALUES(1,1);
|
||||
INSERT INTO tt_5(trans_id, stmt_id) VALUES(1,1);
|
||||
INSERT INTO tt_6(trans_id, stmt_id) VALUES(1,1);
|
||||
|
||||
DELIMITER |;
|
||||
|
||||
CREATE PROCEDURE pc_i_tt_5_suc (IN p_trans_id INTEGER, IN p_stmt_id INTEGER)
|
||||
BEGIN
|
||||
DECLARE in_stmt_id INTEGER;
|
||||
SELECT max(stmt_id) INTO in_stmt_id FROM tt_5 WHERE trans_id= p_trans_id;
|
||||
SELECT COALESCE(greatest(in_stmt_id + 1, p_stmt_id), 1) INTO in_stmt_id;
|
||||
INSERT INTO tt_5(trans_id, stmt_id) VALUES (p_trans_id, in_stmt_id);
|
||||
INSERT INTO tt_5(trans_id, stmt_id) VALUES (p_trans_id, in_stmt_id + 1);
|
||||
END|
|
||||
|
||||
CREATE PROCEDURE pc_i_nt_5_suc (IN p_trans_id INTEGER, IN p_stmt_id INTEGER)
|
||||
BEGIN
|
||||
DECLARE in_stmt_id INTEGER;
|
||||
SELECT max(stmt_id) INTO in_stmt_id FROM nt_5 WHERE trans_id= p_trans_id;
|
||||
SELECT COALESCE(greatest(in_stmt_id + 1, p_stmt_id), 1) INTO in_stmt_id;
|
||||
INSERT INTO nt_5(trans_id, stmt_id) VALUES (p_trans_id, in_stmt_id);
|
||||
INSERT INTO nt_5(trans_id, stmt_id) VALUES (p_trans_id, in_stmt_id + 1);
|
||||
END|
|
||||
|
||||
CREATE FUNCTION fc_i_tt_5_suc (p_trans_id INTEGER, p_stmt_id INTEGER) RETURNS VARCHAR(64)
|
||||
BEGIN
|
||||
DECLARE in_stmt_id INTEGER;
|
||||
SELECT max(stmt_id) INTO in_stmt_id FROM tt_5 WHERE trans_id= p_trans_id;
|
||||
SELECT COALESCE(greatest(in_stmt_id + 1, p_stmt_id), 1) INTO in_stmt_id;
|
||||
INSERT INTO tt_5(trans_id, stmt_id) VALUES (p_trans_id, in_stmt_id);
|
||||
INSERT INTO tt_5(trans_id, stmt_id) VALUES (p_trans_id, in_stmt_id + 1);
|
||||
RETURN "fc_i_tt_5_suc";
|
||||
END|
|
||||
|
||||
CREATE FUNCTION fc_i_nt_5_suc (p_trans_id INTEGER, p_stmt_id INTEGER) RETURNS VARCHAR(64)
|
||||
BEGIN
|
||||
DECLARE in_stmt_id INTEGER;
|
||||
SELECT max(stmt_id) INTO in_stmt_id FROM nt_5 WHERE trans_id= p_trans_id;
|
||||
SELECT COALESCE(greatest(in_stmt_id + 1, p_stmt_id), 1) INTO in_stmt_id;
|
||||
INSERT INTO nt_5(trans_id, stmt_id) VALUES (p_trans_id, in_stmt_id);
|
||||
INSERT INTO nt_5(trans_id, stmt_id) VALUES (p_trans_id, in_stmt_id + 1);
|
||||
RETURN "fc_i_nt_5_suc";
|
||||
END|
|
||||
|
||||
CREATE TRIGGER tr_i_tt_3_to_nt_3 AFTER INSERT ON tt_3 FOR EACH ROW
|
||||
BEGIN
|
||||
DECLARE in_stmt_id INTEGER;
|
||||
SELECT max(stmt_id) INTO in_stmt_id FROM nt_3 WHERE trans_id= NEW.trans_id;
|
||||
SELECT COALESCE(greatest(in_stmt_id + 1, NEW.stmt_id), 1) INTO in_stmt_id;
|
||||
INSERT INTO nt_3(trans_id, stmt_id) VALUES (NEW.trans_id, in_stmt_id);
|
||||
INSERT INTO nt_3(trans_id, stmt_id) VALUES (NEW.trans_id, in_stmt_id + 1);
|
||||
END|
|
||||
|
||||
CREATE TRIGGER tr_i_nt_4_to_tt_4 AFTER INSERT ON nt_4 FOR EACH ROW
|
||||
BEGIN
|
||||
DECLARE in_stmt_id INTEGER;
|
||||
SELECT max(stmt_id) INTO in_stmt_id FROM tt_4 WHERE trans_id= NEW.trans_id;
|
||||
SELECT COALESCE(greatest(in_stmt_id + 1, NEW.stmt_id), 1) INTO in_stmt_id;
|
||||
INSERT INTO tt_4(trans_id, stmt_id) VALUES (NEW.trans_id, in_stmt_id);
|
||||
INSERT INTO tt_4(trans_id, stmt_id) VALUES (NEW.trans_id, in_stmt_id + 1);
|
||||
END|
|
||||
|
||||
CREATE TRIGGER tr_i_tt_5_to_tt_6 AFTER INSERT ON tt_5 FOR EACH ROW
|
||||
BEGIN
|
||||
DECLARE in_stmt_id INTEGER;
|
||||
SELECT max(stmt_id) INTO in_stmt_id FROM tt_6 WHERE trans_id= NEW.trans_id;
|
||||
SELECT COALESCE(greatest(in_stmt_id + 1, NEW.stmt_id, 1), 1) INTO in_stmt_id;
|
||||
INSERT INTO tt_6(trans_id, stmt_id) VALUES (NEW.trans_id, in_stmt_id);
|
||||
INSERT INTO tt_6(trans_id, stmt_id) VALUES (NEW.trans_id, in_stmt_id + 1);
|
||||
END|
|
||||
|
||||
CREATE TRIGGER tr_i_nt_5_to_nt_6 AFTER INSERT ON nt_5 FOR EACH ROW
|
||||
BEGIN
|
||||
DECLARE in_stmt_id INTEGER;
|
||||
SELECT max(stmt_id) INTO in_stmt_id FROM nt_6 WHERE trans_id= NEW.trans_id;
|
||||
SELECT COALESCE(greatest(in_stmt_id + 1, NEW.stmt_id), 1) INTO in_stmt_id;
|
||||
INSERT INTO nt_6(trans_id, stmt_id) VALUES (NEW.trans_id, in_stmt_id);
|
||||
INSERT INTO nt_6(trans_id, stmt_id) VALUES (NEW.trans_id, in_stmt_id + 1);
|
||||
END|
|
||||
|
||||
DELIMITER ;|
|
||||
|
||||
let $pos_trans_command= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
|
||||
let $trans_id= 7;
|
||||
let $tb_id= 1;
|
||||
let $stmt_id= 1;
|
||||
let $commands= '';
|
||||
|
||||
SET @commands= '';
|
||||
}
|
||||
|
||||
if (`SELECT HEX(@commands) = HEX('clean')`)
|
||||
{
|
||||
connection master;
|
||||
|
||||
DROP TABLE tt_1;
|
||||
DROP TABLE tt_2;
|
||||
DROP TABLE tt_3;
|
||||
DROP TABLE tt_4;
|
||||
DROP TABLE tt_5;
|
||||
DROP TABLE tt_6;
|
||||
|
||||
DROP TABLE nt_1;
|
||||
DROP TABLE nt_2;
|
||||
DROP TABLE nt_3;
|
||||
DROP TABLE nt_4;
|
||||
DROP TABLE nt_5;
|
||||
DROP TABLE nt_6;
|
||||
|
||||
DROP PROCEDURE pc_i_tt_5_suc;
|
||||
DROP PROCEDURE pc_i_nt_5_suc;
|
||||
DROP FUNCTION fc_i_tt_5_suc;
|
||||
DROP FUNCTION fc_i_nt_5_suc;
|
||||
|
||||
sync_slave_with_master;
|
||||
|
||||
SET @commands= '';
|
||||
}
|
||||
|
||||
while (`SELECT HEX(@commands) != HEX('')`)
|
||||
{
|
||||
--disable_query_log
|
||||
SET @command= SUBSTRING_INDEX(@commands, ' ', 1);
|
||||
let $command= `SELECT @command`;
|
||||
--eval SET @check_commands= '$commands'
|
||||
if (`SELECT HEX(@check_commands) = HEX('''')`)
|
||||
{
|
||||
let $commands= `SELECT @commands`;
|
||||
}
|
||||
--echo -b-b-b-b-b-b-b-b-b-b-b- >> $command << -b-b-b-b-b-b-b-b-b-b-b-
|
||||
let $pos_command= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
--enable_query_log
|
||||
if (`SELECT HEX(@command) = HEX('B')`)
|
||||
{
|
||||
eval BEGIN;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('T')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval INSERT INTO tt_1(trans_id, stmt_id) VALUES ($trans_id, $stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('T-trig')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval INSERT INTO tt_5(trans_id, stmt_id) VALUES ($trans_id, $stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('T-func')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval SELECT fc_i_tt_5_suc ($trans_id, $stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('T-proc')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval CALL pc_i_tt_5_suc ($trans_id, $stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('eT')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from tt_1`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from tt_1 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO tt_1(trans_id, stmt_id) VALUES ($old_trans_id, $old_stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('Te')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from tt_1`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from tt_1 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO tt_1(trans_id, stmt_id) VALUES ($trans_id, $stmt_id), ($old_trans_id, $old_stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('Te-trig')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from tt_5`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from tt_5 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO tt_5(trans_id, stmt_id) VALUES ($trans_id, $stmt_id), ($old_trans_id, $old_stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('Te-func')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from tt_1`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from tt_1 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO tt_1(trans_id, stmt_id, info) VALUES ($trans_id, $stmt_id, ''), ($old_trans_id, $old_stmt_id, fc_i_tt_5_suc ($trans_id, $stmt_id));
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('N')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval INSERT INTO nt_1(trans_id, stmt_id) VALUES ($trans_id, $stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('N-trig')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval INSERT INTO nt_5(trans_id, stmt_id) VALUES ($trans_id, $stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('N-func')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval SELECT fc_i_nt_5_suc ($trans_id, $stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('N-proc')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval CALL pc_i_nt_5_suc ($trans_id, $stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('eN')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from nt_1`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from nt_1 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO nt_1(trans_id, stmt_id) VALUES ($old_trans_id, $old_stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('Ne')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from nt_1`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from nt_1 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO nt_1(trans_id, stmt_id) VALUES ($trans_id, $stmt_id), ($old_trans_id, $old_stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('Ne-trig')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from nt_5`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from nt_5 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO nt_5(trans_id, stmt_id) VALUES ($trans_id, $stmt_id), ($old_trans_id, $old_stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('Ne-func')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from nt_1`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from nt_1 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO nt_1(trans_id, stmt_id, info) VALUES ($trans_id, $stmt_id, ''), ($old_trans_id, $old_stmt_id, fc_i_nt_5_suc ($trans_id, $stmt_id));
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('tN')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval INSERT INTO nt_1(trans_id, stmt_id, info) SELECT $trans_id, $stmt_id, COUNT(*) FROM tt_1;
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('tNe')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from nt_1`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from nt_1 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO nt_1(trans_id, stmt_id, info) SELECT $trans_id, $stmt_id, COUNT(*) FROM tt_1 UNION SELECT $old_trans_id, $old_stmt_id, COUNT(*) FROM tt_1;
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('nT')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval INSERT INTO tt_1(trans_id, stmt_id, info) SELECT $trans_id, $stmt_id, COUNT(*) FROM nt_1;
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('nTe')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from tt_1`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from tt_1 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO tt_1(trans_id, stmt_id, info) SELECT $trans_id, $stmt_id, COUNT(*) FROM nt_1 UNION SELECT $old_trans_id, $old_stmt_id, COUNT(*) FROM nt_1;
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('NT')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval UPDATE nt_3, tt_3 SET nt_3.info= "new text $trans_id --> $stmt_id", tt_3.info= "new text $trans_id --> $stmt_id" where nt_3.trans_id = tt_3.trans_id and tt_3.trans_id = 1;
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('NT-trig')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval INSERT INTO nt_4(trans_id, stmt_id) VALUES ($trans_id, $stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('NT-func')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval INSERT INTO nt_5(trans_id, stmt_id, info) VALUES ($trans_id, $stmt_id, fc_i_tt_5_suc($trans_id, $stmt_id));
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('NeT-trig')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from nt_4`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from nt_4 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO nt_4(trans_id, stmt_id) VALUES ($trans_id, $stmt_id), ($old_trans_id, $old_stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('NeT-func')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from nt_5`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from nt_5 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO nt_5(trans_id, stmt_id, info) VALUES ($trans_id, $stmt_id, ''), ($old_trans_id, $old_stmt_id, fc_i_tt_5_suc ($trans_id, $stmt_id));
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('TN')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval UPDATE tt_4, nt_4 SET tt_4.info= "new text $trans_id --> $stmt_id", nt_4.info= "new text $trans_id --> $stmt_id" where nt_4.trans_id = tt_4.trans_id and tt_4.trans_id = 1;
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('TN-trig')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval INSERT INTO tt_3(trans_id, stmt_id) VALUES ($trans_id, $stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('TN-func')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
eval INSERT INTO tt_5(trans_id, stmt_id, info) VALUES ($trans_id, $stmt_id, fc_i_nt_5_suc($trans_id, $stmt_id));
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('TeN-trig')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from tt_3`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from tt_3 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO tt_3(trans_id, stmt_id) VALUES ($trans_id, $stmt_id), ($old_trans_id, $old_stmt_id);
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('TeN-func')`)
|
||||
{
|
||||
#--echo DEBUG-- (trans_id, stmt_id) --> ($trans_id, $stmt_id)
|
||||
let $old_trans_id= `SELECT max(trans_id) from tt_5`;
|
||||
let $old_stmt_id= `SELECT max(stmt_id) from tt_5 where trans_id= $old_trans_id`;
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
eval INSERT INTO tt_5(trans_id, stmt_id, info) VALUES ($trans_id, $stmt_id, ''), ($old_trans_id, $old_stmt_id, fc_i_nt_5_suc ($trans_id, $stmt_id));
|
||||
inc $stmt_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('CS-T->T')`)
|
||||
{
|
||||
--eval CREATE TABLE tt_xx_$tb_id (PRIMARY KEY(trans_id, stmt_id)) engine=$engine_type SELECT * FROM tt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('CS-N->N')`)
|
||||
{
|
||||
--eval CREATE TABLE nt_xx_$tb_id (PRIMARY KEY(trans_id, stmt_id)) engine=MyIsam SELECT * FROM nt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('CS-T->N')`)
|
||||
{
|
||||
--eval CREATE TABLE tt_xx_$tb_id (PRIMARY KEY(trans_id, stmt_id)) engine=$engine_type SELECT * FROM nt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('CS-N->T')`)
|
||||
{
|
||||
--eval CREATE TABLE nt_xx_$tb_id (PRIMARY KEY(trans_id, stmt_id)) engine=MyIsam SELECT * FROM tt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('CSe-T->T')`)
|
||||
{
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
--eval CREATE TABLE tt_xx_$tb_id (PRIMARY KEY (stmt_id)) engine=$engine_type SELECT stmt_id FROM tt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('CSe-N->N')`)
|
||||
{
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
--eval CREATE TABLE nt_xx_$tb_id (PRIMARY KEY (stmt_id)) engine=MyIsam SELECT stmt_id FROM nt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('CSe-T->N')`)
|
||||
{
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
--eval CREATE TABLE tt_xx_$tb_id (PRIMARY KEY (stmt_id)) engine=$engine_type SELECT stmt_id FROM nt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('CSe-N->T')`)
|
||||
{
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
--eval CREATE TABLE nt_xx_$tb_id (PRIMARY KEY (stmt_id)) engine=MyIsam SELECT stmt_id FROM tt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('CT')`)
|
||||
{
|
||||
--eval CREATE TEMPORARY TABLE tt_xx_$tb_id (a int) engine=$engine_type;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('IS-T<-N')`)
|
||||
{
|
||||
--eval INSERT INTO tt_xx_$tb_id(trans_id, stmt_id, info) SELECT trans_id, stmt_id, USER() FROM nt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('ISe-T<-N')`)
|
||||
{
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
--eval INSERT INTO tt_xx_$tb_id(trans_id, stmt_id, info) SELECT trans_id, trans_id, USER() FROM nt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('IS-N<-T')`)
|
||||
{
|
||||
--eval INSERT INTO nt_xx_$tb_id(trans_id, stmt_id, info) SELECT trans_id, stmt_id, USER() FROM tt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('ISe-N<-T')`)
|
||||
{
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
--eval INSERT INTO nt_xx_$tb_id(trans_id, stmt_id, info) SELECT trans_id, trans_id, USER() FROM tt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('IS-T<-T')`)
|
||||
{
|
||||
--eval INSERT INTO tt_xx_$tb_id(trans_id, stmt_id, info) SELECT trans_id, stmt_id, USER() FROM tt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('ISe-T<-T')`)
|
||||
{
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
--eval INSERT INTO tt_xx_$tb_id(trans_id, stmt_id, info) SELECT trans_id, trans_id, USER() FROM tt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('IS-N<-N')`)
|
||||
{
|
||||
--eval INSERT INTO nt_xx_$tb_id(trans_id, stmt_id, info) SELECT trans_id, stmt_id, USER() FROM nt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('ISe-N<-N')`)
|
||||
{
|
||||
--error ER_DUP_ENTRY, ER_DUP_KEY
|
||||
--eval INSERT INTO nt_xx_$tb_id(trans_id, stmt_id, info) SELECT trans_id, trans_id, USER() FROM nt_1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('trunc-CS-T')`)
|
||||
{
|
||||
eval TRUNCATE TABLE tt_xx_$tb_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('trunc-CS-N')`)
|
||||
{
|
||||
eval TRUNCATE TABLE nt_xx_$tb_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('trunc-CT')`)
|
||||
{
|
||||
eval TRUNCATE TABLE tt_xx_$tb_id;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('drop-CS')`)
|
||||
{
|
||||
--disable_warnings
|
||||
eval DROP TABLE IF EXISTS tt_xx_$tb_id, nt_xx_$tb_id;
|
||||
inc $tb_id;
|
||||
--enable_warnings
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('drop-CT')`)
|
||||
{
|
||||
--disable_warnings
|
||||
eval DROP TEMPORARY TABLE IF EXISTS tt_xx_$tb_id;
|
||||
inc $tb_id;
|
||||
--enable_warnings
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('C')`)
|
||||
{
|
||||
--error 0, ER_GET_ERRMSG
|
||||
eval COMMIT;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('R')`)
|
||||
{
|
||||
--error 0, ER_GET_ERRMSG
|
||||
eval ROLLBACK;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('S1')`)
|
||||
{
|
||||
eval SAVEPOINT s1;
|
||||
}
|
||||
if (`SELECT HEX(@command) = HEX('R1')`)
|
||||
{
|
||||
eval ROLLBACK TO s1;
|
||||
}
|
||||
--disable_query_log
|
||||
SET @commands= LTRIM(SUBSTRING(@commands, LENGTH(@command) + 1));
|
||||
inc $stmt_id;
|
||||
|
||||
let $binlog_start= $pos_command;
|
||||
--source include/show_binlog_events.inc
|
||||
--echo -e-e-e-e-e-e-e-e-e-e-e- >> $command << -e-e-e-e-e-e-e-e-e-e-e-
|
||||
if (`SELECT HEX(@commands) = HEX('')`)
|
||||
{
|
||||
let $binlog_start= $pos_trans_command;
|
||||
--echo -b-b-b-b-b-b-b-b-b-b-b- >> $commands << -b-b-b-b-b-b-b-b-b-b-b-
|
||||
--source include/show_binlog_events.inc
|
||||
--echo -e-e-e-e-e-e-e-e-e-e-e- >> $commands << -e-e-e-e-e-e-e-e-e-e-e-
|
||||
--echo
|
||||
let $pos_trans_command= query_get_value("SHOW MASTER STATUS", Position, 1);
|
||||
let $stmt_id= 1;
|
||||
inc $trans_id;
|
||||
let $commands= '';
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -141,7 +141,9 @@ let $run= 5;
|
||||
while ($run)
|
||||
{
|
||||
START TRANSACTION;
|
||||
--disable_warnings
|
||||
--eval CALL tpcb.trans($rpl_format);
|
||||
--enable_warnings
|
||||
eval SET @my_errno= $mysql_errno;
|
||||
let $run_good= `SELECT @my_errno = 0`;
|
||||
let $run_bad= `SELECT @my_errno <> 0`;
|
||||
@@ -190,7 +192,9 @@ let $run= 5;
|
||||
while ($run)
|
||||
{
|
||||
START TRANSACTION;
|
||||
--disable_warnings
|
||||
--eval CALL tpcb.trans($rpl_format);
|
||||
--enable_warnings
|
||||
eval SET @my_errno= $mysql_errno;
|
||||
let $run_good= `SELECT @my_errno = 0`;
|
||||
let $run_bad= `SELECT @my_errno <> 0`;
|
||||
@@ -240,7 +244,9 @@ let $run= 5;
|
||||
while ($run)
|
||||
{
|
||||
START TRANSACTION;
|
||||
--disable_warnings
|
||||
--eval CALL tpcb.trans($rpl_format);
|
||||
--enable_warnings
|
||||
eval SET @my_errno= $mysql_errno;
|
||||
let $run_good= `SELECT @my_errno = 0`;
|
||||
let $run_bad= `SELECT @my_errno <> 0`;
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
# First we test tables with only an index.
|
||||
#
|
||||
|
||||
connection master;
|
||||
eval CREATE TABLE t1 (C1 CHAR(1), C2 CHAR(1), INDEX (C1)$extra_index_t1) ENGINE = $type ;
|
||||
SELECT * FROM t1;
|
||||
sync_slave_with_master;
|
||||
@@ -156,6 +157,12 @@ SELECT * FROM t5,t2,t3 WHERE t5.C2='Q' AND t2.c12='R' AND t3.C3 ='S' ORDER BY t5
|
||||
# Testing special column types
|
||||
#
|
||||
|
||||
if (`select char_length('$bit_field_special') > 0`) {
|
||||
SET @saved_slave_type_conversions = @@SLAVE_TYPE_CONVERSIONS;
|
||||
connection slave;
|
||||
eval SET GLOBAL SLAVE_TYPE_CONVERSIONS = '$bit_field_special';
|
||||
}
|
||||
|
||||
connection master;
|
||||
eval CREATE TABLE t4 (C1 CHAR(1) PRIMARY KEY, B1 BIT(1), B2 BIT(1) NOT NULL DEFAULT 0, C2 CHAR(1) NOT NULL DEFAULT 'A') ENGINE = $type ;
|
||||
|
||||
@@ -164,6 +171,10 @@ SELECT C1,HEX(B1),HEX(B2) FROM t4 ORDER BY C1;
|
||||
sync_slave_with_master;
|
||||
SELECT C1,HEX(B1),HEX(B2) FROM t4 ORDER BY C1;
|
||||
|
||||
if (`select char_length('$bit_field_special') > 0`) {
|
||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS = @saved_slave_type_conversions;
|
||||
}
|
||||
|
||||
#
|
||||
# Testing conflicting operations
|
||||
#
|
||||
@@ -350,6 +361,10 @@ eval CREATE TABLE t7 (i INT NOT NULL,
|
||||
c CHAR(255) CHARACTER SET utf8 NOT NULL,
|
||||
j INT NOT NULL) ENGINE = $type ;
|
||||
|
||||
connection slave;
|
||||
SET @saved_slave_type_conversions = @@slave_type_conversions;
|
||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS = 'ALL_NON_LOSSY';
|
||||
|
||||
--echo [expecting slave to replicate correctly]
|
||||
connection master;
|
||||
INSERT INTO t1 VALUES (1, "", 1);
|
||||
@@ -370,17 +385,9 @@ let $diff_table_1=master:test.t2;
|
||||
let $diff_table_2=slave:test.t2;
|
||||
source include/diff_tables.inc;
|
||||
|
||||
--echo [expecting slave to stop]
|
||||
connection master;
|
||||
INSERT INTO t3 VALUES (1, "", 1);
|
||||
INSERT INTO t3 VALUES (2, repeat(_utf8'a', 128), 2);
|
||||
|
||||
connection slave;
|
||||
source include/wait_for_slave_sql_to_stop.inc;
|
||||
let $last_error = query_get_value("SHOW SLAVE STATUS", Last_SQL_Error, 1);
|
||||
disable_query_log;
|
||||
eval SELECT "$last_error" AS Last_SQL_Error;
|
||||
enable_query_log;
|
||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS = @saved_slave_type_conversions;
|
||||
|
||||
connection master;
|
||||
RESET MASTER;
|
||||
connection slave;
|
||||
@@ -600,7 +607,15 @@ sync_slave_with_master;
|
||||
|
||||
connection master;
|
||||
|
||||
# Since t1 contain a bit field, we have to do this trick to handle InnoDB
|
||||
if (`select char_length('$bit_field_special') > 0`) {
|
||||
SET @saved_slave_type_conversions = @@SLAVE_TYPE_CONVERSIONS;
|
||||
connection slave;
|
||||
eval SET GLOBAL SLAVE_TYPE_CONVERSIONS = '$bit_field_special';
|
||||
}
|
||||
|
||||
--disable_warnings
|
||||
connection master;
|
||||
eval CREATE TABLE t1 (a bit) ENGINE=$type;
|
||||
INSERT IGNORE INTO t1 VALUES (NULL);
|
||||
INSERT INTO t1 ( a ) VALUES ( 0 );
|
||||
@@ -645,6 +660,10 @@ UPDATE t1 SET a = 9 WHERE a < 5 LIMIT 3;
|
||||
|
||||
sync_slave_with_master;
|
||||
|
||||
if (`select char_length('$bit_field_special') > 0`) {
|
||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS = @saved_slave_type_conversions;
|
||||
}
|
||||
|
||||
let $diff_table_1=master:test.t1;
|
||||
let $diff_table_2=slave:test.t1;
|
||||
source include/diff_tables.inc;
|
||||
|
||||
@@ -23,7 +23,7 @@ let $binary_log_limit_row= 3;
|
||||
|
||||
-- echo [MASTER] ********* SOW BINLOG EVENTS ... LIMIT offset,rows *********
|
||||
let $binary_log_file= ;
|
||||
let $binary_log_limit_row= 3;
|
||||
let $binary_log_limit_row= 4;
|
||||
let $binary_log_limit_offset= 1;
|
||||
-- source include/show_binlog_events.inc
|
||||
|
||||
@@ -49,7 +49,7 @@ let $binary_log_limit_row= 3;
|
||||
|
||||
-- echo [SLAVE] ********* SOW BINLOG EVENTS ... LIMIT offset,rows *********
|
||||
let $binary_log_file= ;
|
||||
let $binary_log_limit_row= 3;
|
||||
let $binary_log_limit_row= 4;
|
||||
let $binary_log_limit_offset= 1;
|
||||
-- source include/show_binlog_events.inc
|
||||
|
||||
|
||||
@@ -1,10 +1,14 @@
|
||||
source include/master-slave.inc;
|
||||
source include/have_innodb.inc;
|
||||
|
||||
#
|
||||
# Bug#6148 ()
|
||||
#
|
||||
# Let the master do lots of insertions
|
||||
|
||||
connection master;
|
||||
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||
|
||||
connection slave;
|
||||
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||
|
||||
connection master;
|
||||
create table t1(n int);
|
||||
sync_slave_with_master;
|
||||
@@ -3,7 +3,7 @@
|
||||
-- source include/have_binlog_format_statement.inc
|
||||
-- source include/master-slave.inc
|
||||
|
||||
CALL mtr.add_suppression("Statement may not be safe to log in statement format.");
|
||||
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||
|
||||
# Load some data into t1
|
||||
create table t1 (word char(20) not null);
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
-- source include/have_debug.inc
|
||||
-- source include/master-slave.inc
|
||||
-- source include/have_innodb.inc
|
||||
|
||||
# Proving that stopping in the middle of applying a group of events
|
||||
# does not have immediate effect if a non-transaction table has been changed.
|
||||
# The slave sql thread has to try to finish applying first.
|
||||
@@ -11,6 +7,8 @@
|
||||
|
||||
connection master;
|
||||
|
||||
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||
|
||||
create table tm (a int auto_increment primary key) engine=myisam;
|
||||
create table ti (a int auto_increment primary key) engine=innodb;
|
||||
|
||||
882
mysql-test/extra/rpl_tests/type_conversions.test
Normal file
882
mysql-test/extra/rpl_tests/type_conversions.test
Normal file
@@ -0,0 +1,882 @@
|
||||
# File containing different lossy and non-lossy type conversions.
|
||||
|
||||
# Integral conversion testing, we do not reduce the test using
|
||||
# transitivity of conversions since the implementation is not using a
|
||||
# transitivity strategy. Instead we do an exhaustive testing.
|
||||
|
||||
disable_query_log;
|
||||
connection slave;
|
||||
--let $conv = `select @@slave_type_conversions`
|
||||
--echo **** Running tests with @@SLAVE_TYPE_CONVERSIONS = '$conv' ****
|
||||
|
||||
let $if_is_lossy = `SELECT FIND_IN_SET('ALL_LOSSY', @@SLAVE_TYPE_CONVERSIONS)`;
|
||||
let $if_is_non_lossy = `SELECT FIND_IN_SET('ALL_NON_LOSSY', @@SLAVE_TYPE_CONVERSIONS)`;
|
||||
|
||||
# TINYBLOB
|
||||
|
||||
let $source_type = TINYBLOB;
|
||||
let $target_type = TINYBLOB;
|
||||
let $source_value = 'aaa';
|
||||
let $target_value = 'aaa';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TINYBLOB;
|
||||
let $target_type= BLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TINYBLOB;
|
||||
let $target_type= MEDIUMBLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TINYBLOB;
|
||||
let $target_type= LONGBLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
# BLOB
|
||||
|
||||
let $source_type = BLOB;
|
||||
let $target_type = TINYBLOB;
|
||||
let $source_value = 'aaa';
|
||||
let $target_value = 'aaa';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BLOB;
|
||||
let $target_type= BLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BLOB;
|
||||
let $target_type= MEDIUMBLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BLOB;
|
||||
let $target_type= LONGBLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
# MEDIUMBLOB
|
||||
|
||||
let $source_type = MEDIUMBLOB;
|
||||
let $target_type = TINYBLOB;
|
||||
let $source_value = 'aaa';
|
||||
let $target_value = 'aaa';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMBLOB;
|
||||
let $target_type= BLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMBLOB;
|
||||
let $target_type= MEDIUMBLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMBLOB;
|
||||
let $target_type= LONGBLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
# LONGBLOB
|
||||
|
||||
let $source_type = LONGBLOB;
|
||||
let $target_type = TINYBLOB;
|
||||
let $source_value = 'aaa';
|
||||
let $target_value = 'aaa';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= LONGBLOB;
|
||||
let $target_type= BLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= LONGBLOB;
|
||||
let $target_type= MEDIUMBLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= LONGBLOB;
|
||||
let $target_type= LONGBLOB;
|
||||
let $source_value= 'aaa';
|
||||
let $target_value= 'aaa';
|
||||
let $can_convert= 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
# BUG#49836 (additional tests - GEOMETRY TYPE)
|
||||
|
||||
let $source_type = GEOMETRY;
|
||||
let $target_type = BLOB;
|
||||
let $source_value = PointFromText('POINT(10 10)');
|
||||
let $target_value = PointFromText('POINT(10 10)');
|
||||
let $can_convert = 0;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = BLOB;
|
||||
let $target_type = GEOMETRY;
|
||||
let $source_value = 'aaa';
|
||||
let $target_value = 'aaa';
|
||||
let $can_convert = 0;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = GEOMETRY;
|
||||
let $target_type = GEOMETRY;
|
||||
let $source_value = PointFromText('POINT(10 10)');
|
||||
let $target_value = PointFromText('POINT(10 10)');
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = BIT(1);
|
||||
let $target_type = BIT(1);
|
||||
let $source_value = b'1';
|
||||
let $target_value = b'1';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = DATE;
|
||||
let $target_type = DATE;
|
||||
let $source_value = '2009-11-21';
|
||||
let $target_value = '2009-11-21';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = ENUM('master','slave');
|
||||
let $target_type = ENUM('master','slave');
|
||||
let $source_value = 'master';
|
||||
let $target_value = 'master';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = CHAR(10);
|
||||
let $target_type = ENUM('master','slave');
|
||||
let $source_value = 'master';
|
||||
let $target_value = 'master';
|
||||
let $can_convert = 0;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = CHAR(10);
|
||||
let $target_type = SET('master','slave');
|
||||
let $source_value = 'master';
|
||||
let $target_value = 'master';
|
||||
let $can_convert = 0;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = ENUM('master','slave');
|
||||
let $target_type = CHAR(10);
|
||||
let $source_value = 'master';
|
||||
let $target_value = 'master';
|
||||
let $can_convert = 0;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = SET('master','slave');
|
||||
let $target_type = CHAR(10);
|
||||
let $source_value = 'master';
|
||||
let $target_value = 'master';
|
||||
let $can_convert = 0;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = SET('master','slave');
|
||||
let $target_type = SET('master','slave');
|
||||
let $source_value = '';
|
||||
let $target_value = '';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = SET('master','slave');
|
||||
let $target_type = SET('master','slave');
|
||||
let $source_value = 'master,slave';
|
||||
let $target_value = 'master,slave';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = SET('0','1','2','3','4','5','6');
|
||||
let $target_type = SET('0','1','2','3','4','5','6');
|
||||
let $source_value = '5';
|
||||
let $target_value = '5';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = SET('0','1','2','3','4','5','6');
|
||||
let $target_type = SET('0','1','2','3','4','5','6','7','8','9','10');
|
||||
let $source_value = '5';
|
||||
let $target_value = '5';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = SET('0','1','2','3','4','5','6','7','8','9','10');
|
||||
let $target_type = SET('0','1','2','3','4','5','6');
|
||||
let $source_value = '5';
|
||||
let $target_value = '5';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = SET('0','1','2','3','4','5','6','7','8','9','10');
|
||||
let $target_type = SET('0','1','2','3','4','5','6');
|
||||
let $source_value = '7';
|
||||
let $target_value = '';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = TINYINT;
|
||||
let $target_type = TINYINT;
|
||||
let $source_value = 1;
|
||||
let $target_value = 1;
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type = TINYINT;
|
||||
let $target_type = SMALLINT;
|
||||
let $source_value = 1;
|
||||
let $target_value = 1;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TINYINT;
|
||||
let $target_type= MEDIUMINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TINYINT;
|
||||
let $target_type= INT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TINYINT;
|
||||
let $target_type= BIGINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= SMALLINT;
|
||||
let $target_type= TINYINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= SMALLINT;
|
||||
let $target_type= TINYINT;
|
||||
let $source_value= 1 << 9;
|
||||
let $target_value= (1 << 7) - 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= SMALLINT;
|
||||
let $target_type= TINYINT UNSIGNED;
|
||||
let $source_value= 1 << 9;
|
||||
let $target_value= (1 << 8) - 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= SMALLINT;
|
||||
let $target_type= SMALLINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= SMALLINT;
|
||||
let $target_type= MEDIUMINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= SMALLINT;
|
||||
let $target_type= INT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= SMALLINT;
|
||||
let $target_type= BIGINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMINT;
|
||||
let $target_type= TINYINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMINT;
|
||||
let $target_type= TINYINT;
|
||||
let $source_value= 1 << 20;
|
||||
let $target_value= (1 << 7) - 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMINT;
|
||||
let $target_type= TINYINT UNSIGNED;
|
||||
let $source_value= 1 << 20;
|
||||
let $target_value= (1 << 8) - 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMINT;
|
||||
let $target_type= SMALLINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMINT;
|
||||
let $target_type= MEDIUMINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMINT;
|
||||
let $target_type= INT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMINT;
|
||||
let $target_type= BIGINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= INT;
|
||||
let $target_type= TINYINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= INT;
|
||||
let $target_type= TINYINT;
|
||||
let $source_value= (1 << 30);
|
||||
let $target_value= (1 << 7) - 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= INT;
|
||||
let $target_type= TINYINT UNSIGNED;
|
||||
let $source_value= (1 << 30);
|
||||
let $target_value= (1 << 8) - 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= INT;
|
||||
let $target_type= SMALLINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= INT;
|
||||
let $target_type= MEDIUMINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= INT;
|
||||
let $target_type= INT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= INT;
|
||||
let $target_type= BIGINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BIGINT;
|
||||
let $target_type= TINYINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BIGINT;
|
||||
let $target_type= SMALLINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BIGINT;
|
||||
let $target_type= MEDIUMINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BIGINT;
|
||||
let $target_type= INT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BIGINT;
|
||||
let $target_type= BIGINT;
|
||||
let $source_value= 1;
|
||||
let $target_value= 1;
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= CHAR(20);
|
||||
let $target_type= CHAR(20);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= CHAR(20);
|
||||
let $target_type= CHAR(30);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= CHAR(20);
|
||||
let $target_type= CHAR(10);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnood';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= CHAR(20);
|
||||
let $target_type= VARCHAR(20);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= CHAR(20);
|
||||
let $target_type= VARCHAR(30);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= CHAR(20);
|
||||
let $target_type= VARCHAR(10);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnood';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= CHAR(20);
|
||||
let $target_type= TINYTEXT;
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= CHAR(20);
|
||||
let $target_type= TEXT;
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= CHAR(20);
|
||||
let $target_type= MEDIUMTEXT;
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= CHAR(20);
|
||||
let $target_type= LONGTEXT;
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(20);
|
||||
let $target_type= VARCHAR(20);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(20);
|
||||
let $target_type= VARCHAR(30);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(20);
|
||||
let $target_type= VARCHAR(10);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnood';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(20);
|
||||
let $target_type= CHAR(30);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(20);
|
||||
let $target_type= CHAR(10);
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnood';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(20);
|
||||
let $target_type= TINYTEXT;
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(20);
|
||||
let $target_type= TEXT;
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(20);
|
||||
let $target_type= MEDIUMTEXT;
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(20);
|
||||
let $target_type= LONGTEXT;
|
||||
let $source_value= 'Smoothnoodlemaps';
|
||||
let $target_value= 'Smoothnoodlemaps';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $blob = `select repeat('abcd', 125)`;
|
||||
let $truncated_blob = `select left('$blob', 255)`;
|
||||
|
||||
let $source_type= VARCHAR(500);
|
||||
let $target_type= VARCHAR(500);
|
||||
let $source_value= '$blob';
|
||||
let $target_value= '$blob';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(500);
|
||||
let $target_type= VARCHAR(510);
|
||||
let $source_value= '$blob';
|
||||
let $target_value= '$blob';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(500);
|
||||
let $target_type= VARCHAR(255);
|
||||
let $source_value= '$blob';
|
||||
let $target_value= '$truncated_blob';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(500);
|
||||
let $target_type= TINYTEXT;
|
||||
let $source_value= '$blob';
|
||||
let $target_value= '$truncated_blob';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(500);
|
||||
let $target_type= TEXT;
|
||||
let $source_value= '$blob';
|
||||
let $target_value= '$blob';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(500);
|
||||
let $target_type= MEDIUMTEXT;
|
||||
let $source_value= '$blob';
|
||||
let $target_value= '$blob';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= VARCHAR(500);
|
||||
let $target_type= LONGTEXT;
|
||||
let $source_value= '$blob';
|
||||
let $target_value= '$blob';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $tiny_blob = `select repeat('tiny blob ', 25)`;
|
||||
let $truncated_tiny_blob = `select left('$tiny_blob', 254)`;
|
||||
|
||||
let $source_type= TINYTEXT;
|
||||
let $target_type= VARCHAR(500);
|
||||
let $source_value= '$tiny_blob';
|
||||
let $target_value= '$tiny_blob';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TEXT;
|
||||
let $target_type= VARCHAR(500);
|
||||
let $source_value= '$blob';
|
||||
let $target_value= '$blob';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMTEXT;
|
||||
let $target_type= VARCHAR(500);
|
||||
let $source_value= '$blob';
|
||||
let $target_value= '$blob';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= LONGTEXT;
|
||||
let $target_type= VARCHAR(500);
|
||||
let $source_value= '$blob';
|
||||
let $target_value= '$blob';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TINYTEXT;
|
||||
let $target_type= CHAR(255);
|
||||
let $source_value= '$tiny_blob';
|
||||
let $target_value= '$tiny_blob';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TINYTEXT;
|
||||
let $target_type= CHAR(250);
|
||||
let $source_value= '$tiny_blob';
|
||||
let $target_value= left('$tiny_blob', 250);
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TEXT;
|
||||
let $target_type= CHAR(255);
|
||||
let $source_value= '$blob';
|
||||
let $target_value= left('$blob', 255);
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= MEDIUMTEXT;
|
||||
let $target_type= CHAR(255);
|
||||
let $source_value= '$blob';
|
||||
let $target_value= left('$blob', 255);
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= LONGTEXT;
|
||||
let $target_type= CHAR(255);
|
||||
let $source_value= '$blob';
|
||||
let $target_value= left('$blob', 255);
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TINYTEXT;
|
||||
let $target_type= TINYTEXT;
|
||||
let $source_value= '$tiny_blob';
|
||||
let $target_value= '$tiny_blob';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TINYTEXT;
|
||||
let $target_type= TEXT;
|
||||
let $source_value= '$tiny_blob';
|
||||
let $target_value= '$tiny_blob';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= TEXT;
|
||||
let $target_type= TINYTEXT;
|
||||
let $source_value= '$blob';
|
||||
let $target_value= left('$blob',255);
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DECIMAL(10,5);
|
||||
let $target_type= DECIMAL(10,5);
|
||||
let $source_value= 3.14159;
|
||||
let $target_value= 3.14159;
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DECIMAL(10,5);
|
||||
let $target_type= DECIMAL(10,6);
|
||||
let $source_value= 3.14159;
|
||||
let $target_value= 3.141590;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DECIMAL(10,5);
|
||||
let $target_type= DECIMAL(11,5);
|
||||
let $source_value= 3.14159;
|
||||
let $target_value= 3.14159;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DECIMAL(10,5);
|
||||
let $target_type= DECIMAL(11,6);
|
||||
let $source_value= 3.14159;
|
||||
let $target_value= 3.141590;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DECIMAL(10,5);
|
||||
let $target_type= DECIMAL(10,4);
|
||||
let $source_value= 3.14159;
|
||||
let $target_value= 3.1416;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DECIMAL(10,5);
|
||||
let $target_type= DECIMAL(9,5);
|
||||
let $source_value= 3.14159;
|
||||
let $target_value= 3.14159;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DECIMAL(10,5);
|
||||
let $target_type= DECIMAL(9,4);
|
||||
let $source_value= 3.14159;
|
||||
let $target_value= 3.1416;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= FLOAT;
|
||||
let $target_type= DECIMAL(10,5);
|
||||
let $source_value= 3.15625;
|
||||
let $target_value= 3.15625;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DOUBLE;
|
||||
let $target_type= DECIMAL(10,5);
|
||||
let $source_value= 3.15625;
|
||||
let $target_value= 3.15625;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DECIMAL(10,5);
|
||||
let $target_type= FLOAT;
|
||||
let $source_value= 3.15625;
|
||||
let $target_value= 3.15625;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DECIMAL(10,5);
|
||||
let $target_type= DOUBLE;
|
||||
let $source_value= 3.15625;
|
||||
let $target_value= 3.15625;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= FLOAT;
|
||||
let $target_type= FLOAT;
|
||||
let $source_value= 3.15625;
|
||||
let $target_value= 3.15625;
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DOUBLE;
|
||||
let $target_type= DOUBLE;
|
||||
let $source_value= 3.15625;
|
||||
let $target_value= 3.15625;
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= FLOAT;
|
||||
let $target_type= DOUBLE;
|
||||
let $source_value= 3.15625;
|
||||
let $target_value= 3.15625;
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= DOUBLE;
|
||||
let $target_type= FLOAT;
|
||||
let $source_value= 3.15625;
|
||||
let $target_value= 3.15625;
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BIT(5);
|
||||
let $target_type= BIT(5);
|
||||
let $source_value= b'11001';
|
||||
let $target_value= b'11001';
|
||||
let $can_convert = 1;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BIT(5);
|
||||
let $target_type= BIT(6);
|
||||
let $source_value= b'11001';
|
||||
let $target_value= b'11001';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BIT(6);
|
||||
let $target_type= BIT(5);
|
||||
let $source_value= b'111001';
|
||||
let $target_value= b'11111';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BIT(5);
|
||||
let $target_type= BIT(12);
|
||||
let $source_value= b'11001';
|
||||
let $target_value= b'11001';
|
||||
let $can_convert = $if_is_non_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
let $source_type= BIT(12);
|
||||
let $target_type= BIT(5);
|
||||
let $source_value= b'101100111000';
|
||||
let $target_value= b'11111';
|
||||
let $can_convert = $if_is_lossy;
|
||||
source extra/rpl_tests/check_type.inc;
|
||||
|
||||
|
||||
disable_warnings;
|
||||
source include/reset_master_and_slave.inc;
|
||||
enable_warnings;
|
||||
enable_query_log;
|
||||
@@ -547,9 +547,9 @@ call p_verify_status_increment(0, 0, 0, 0);
|
||||
--echo # the binary log.
|
||||
--echo #
|
||||
select f1();
|
||||
call p_verify_status_increment(0, 0, 1, 0);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
commit;
|
||||
call p_verify_status_increment(0, 0, 1, 0);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
|
||||
--echo # 17. Read-only statement, a function changes non-trans-table.
|
||||
--echo #
|
||||
@@ -557,15 +557,19 @@ call p_verify_status_increment(0, 0, 1, 0);
|
||||
--echo # non-transactional changes saved in the transaction cache to
|
||||
--echo # the binary log.
|
||||
--echo #
|
||||
--disable_warnings
|
||||
select f1() from t1;
|
||||
call p_verify_status_increment(1, 0, 2, 0);
|
||||
--enable_warnings
|
||||
call p_verify_status_increment(2, 0, 2, 0);
|
||||
commit;
|
||||
call p_verify_status_increment(1, 0, 2, 0);
|
||||
call p_verify_status_increment(2, 0, 2, 0);
|
||||
|
||||
--echo # 18. Read-write statement: UPDATE, change 0 (transactional) rows.
|
||||
--echo #
|
||||
select count(*) from t2;
|
||||
--disable_warnings
|
||||
update t1 set a=2 where a=f1()+10;
|
||||
--enable_warnings
|
||||
select count(*) from t2;
|
||||
call p_verify_status_increment(2, 0, 2, 0);
|
||||
commit;
|
||||
@@ -579,7 +583,7 @@ call p_verify_status_increment(2, 0, 2, 0);
|
||||
drop table t2;
|
||||
set sql_mode=no_engine_substitution;
|
||||
create temporary table t2 (a int);
|
||||
call p_verify_status_increment(0, 0, 0, 0);
|
||||
call p_verify_status_increment(1, 0, 0, 0);
|
||||
set sql_mode=default;
|
||||
--echo # 19. A function changes temp-trans-table.
|
||||
--echo #
|
||||
@@ -636,9 +640,9 @@ call p_verify_status_increment(2, 0, 1, 0);
|
||||
--echo # 25. DDL: DROP TEMPORARY TABLE, does not start a transaction
|
||||
--echo #
|
||||
drop temporary table t2;
|
||||
call p_verify_status_increment(0, 0, 0, 0);
|
||||
call p_verify_status_increment(1, 0, 0, 0);
|
||||
commit;
|
||||
call p_verify_status_increment(0, 0, 0, 0);
|
||||
call p_verify_status_increment(1, 0, 0, 0);
|
||||
|
||||
--echo # 26. Verify that SET AUTOCOMMIT issues an implicit commit
|
||||
--echo #
|
||||
@@ -719,17 +723,17 @@ call p_verify_status_increment(4, 4, 4, 4);
|
||||
--echo # Sic: no table is created.
|
||||
create table if not exists t2 (a int) select 6 union select 7;
|
||||
--echo # Sic: first commits the statement, and then the transaction.
|
||||
call p_verify_status_increment(4, 4, 4, 4);
|
||||
call p_verify_status_increment(2, 0, 4, 4);
|
||||
create table t3 select a from t2;
|
||||
call p_verify_status_increment(4, 4, 4, 4);
|
||||
call p_verify_status_increment(2, 0, 4, 4);
|
||||
alter table t3 add column (b int);
|
||||
call p_verify_status_increment(2, 0, 2, 0);
|
||||
alter table t3 rename t4;
|
||||
call p_verify_status_increment(2, 2, 2, 2);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
rename table t4 to t3;
|
||||
call p_verify_status_increment(2, 2, 2, 2);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
truncate table t3;
|
||||
call p_verify_status_increment(4, 4, 4, 4);
|
||||
call p_verify_status_increment(2, 0, 2, 0);
|
||||
create view v1 as select * from t2;
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
check table t1;
|
||||
|
||||
@@ -1,3 +1,18 @@
|
||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
# Use default setting for mysqld processes
|
||||
!include default_mysqld.cnf
|
||||
!include default_client.cnf
|
||||
@@ -9,6 +24,8 @@
|
||||
|
||||
log-bin= master-bin
|
||||
|
||||
# Run tests with the performance schema instrumentation
|
||||
loose-enable-performance-schema
|
||||
|
||||
[mysqlbinlog]
|
||||
disable-force-if-open
|
||||
|
||||
@@ -1,3 +1,18 @@
|
||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
# Default values that applies to all MySQL Servers
|
||||
[mysqld]
|
||||
open-files-limit= 1024
|
||||
@@ -26,3 +41,6 @@ slave-net-timeout=120
|
||||
|
||||
log-bin=mysqld-bin
|
||||
|
||||
# Run tests with the performance schema instrumentation
|
||||
loose-enable-performance-schema
|
||||
|
||||
|
||||
@@ -60,6 +60,7 @@ disable_query_log;
|
||||
--error 0,1
|
||||
--remove_file $MYSQLTEST_VARDIR/tmp/diff_table_2
|
||||
|
||||
|
||||
let $_diff_table=$diff_table_2;
|
||||
let $_diff_i=2;
|
||||
while ($_diff_i) {
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
#
|
||||
# Whether server supports dynamic loading.
|
||||
#
|
||||
--require r/have_dynamic_loading.require
|
||||
if (`SELECT @@have_dynamic_loading != 'YES'`) {
|
||||
--skip The test requires dynamic loading
|
||||
}
|
||||
disable_query_log;
|
||||
show variables like 'have_dynamic_loading';
|
||||
enable_query_log;
|
||||
|
||||
@@ -1,13 +1,21 @@
|
||||
#
|
||||
# Check if server has support for loading udf's
|
||||
# i.e it will support dlopen
|
||||
# Check if server has support for loading plugins
|
||||
#
|
||||
--source include/have_dynamic_loading.inc
|
||||
if (`SELECT @@have_dynamic_loading != 'YES'`) {
|
||||
--skip Example plugin requires dynamic loading
|
||||
}
|
||||
|
||||
#
|
||||
# Check if the variable EXAMPLE_PLUGIN is set
|
||||
#
|
||||
--require r/have_example_plugin.require
|
||||
disable_query_log;
|
||||
eval select LENGTH('$EXAMPLE_PLUGIN') > 0 as 'have_example_plugin';
|
||||
if (`SELECT LENGTH('$EXAMPLE_PLUGIN') = 0`) {
|
||||
--skip Example plugin requires the environment variable \$EXAMPLE_PLUGIN to be set (normally done by mtr)
|
||||
}
|
||||
|
||||
#
|
||||
# Check if --plugin-dir was setup for exampledb
|
||||
#
|
||||
if (`SELECT CONCAT('--plugin-dir=', @@plugin_dir) != '$EXAMPLE_PLUGIN_OPT'`) {
|
||||
--skip Example plugin requires that --plugin-dir is set to the example plugin dir (either the .opt file does not contain \$EXAMPLE_PLUGIN_OPT or another plugin is in use)
|
||||
}
|
||||
enable_query_log;
|
||||
|
||||
20
mysql-test/include/have_perfschema.inc
Normal file
20
mysql-test/include/have_perfschema.inc
Normal file
@@ -0,0 +1,20 @@
|
||||
# Copyright (C) 2010 Sun Microsystems, Inc.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
if (!`SELECT count(*) FROM information_schema.engines WHERE
|
||||
(support = 'YES' OR support = 'DEFAULT') AND
|
||||
engine = 'PERFORMANCE_SCHEMA'`){
|
||||
skip Need performance schema compiled in;
|
||||
}
|
||||
@@ -1,10 +1,9 @@
|
||||
#
|
||||
# Check if dynamic loading is supported
|
||||
# Check if server has support for loading plugins
|
||||
#
|
||||
--require r/have_dynamic_loading.require
|
||||
disable_query_log;
|
||||
show variables like 'have_dynamic_loading';
|
||||
enable_query_log;
|
||||
if (`SELECT @@have_dynamic_loading != 'YES'`) {
|
||||
--skip Requires dynamic loading
|
||||
}
|
||||
|
||||
#
|
||||
# Check if the variable SEMISYNC_MASTER_PLUGIN is set
|
||||
|
||||
@@ -1,13 +1,20 @@
|
||||
#
|
||||
# Check if server has support for loading udf's
|
||||
# i.e it will support dlopen
|
||||
# Check if server has support for loading plugins
|
||||
#
|
||||
--source include/have_dynamic_loading.inc
|
||||
if (`SELECT @@have_dynamic_loading != 'YES'`) {
|
||||
--skip simple parser requires dynamic loading
|
||||
}
|
||||
|
||||
#
|
||||
# Check if the variable SIMPLE_PARSER is set
|
||||
#
|
||||
--require r/have_simple_parser.require
|
||||
disable_query_log;
|
||||
eval select LENGTH('$SIMPLE_PARSER') > 0 as 'have_simple_parser';
|
||||
enable_query_log;
|
||||
if (`SELECT LENGTH('$SIMPLE_PARSER') = 0`) {
|
||||
--skip simple parser requires the environment variable \$SIMPLE_PARSER to be set (normally done by mtr)
|
||||
}
|
||||
|
||||
#
|
||||
# Check if --plugin-dir was setup for simple parser
|
||||
#
|
||||
if (`SELECT CONCAT('--plugin-dir=', @@plugin_dir) != '$SIMPLE_PARSER_OPT'`) {
|
||||
--skip simple parser requires that --plugin-dir is set to the udf plugin dir (either the .opt file does not contain \$UDF_EXAMPLE_LIB_OPT or another plugin is in use)
|
||||
}
|
||||
|
||||
10
mysql-test/include/have_thread_concurrency.inc
Normal file
10
mysql-test/include/have_thread_concurrency.inc
Normal file
@@ -0,0 +1,10 @@
|
||||
disable_query_log;
|
||||
disable_result_log;
|
||||
set @have_thread_concurrency=0;
|
||||
select @have_thread_concurrency:=1 from information_schema.global_variables where variable_name='thread_concurrency';
|
||||
if (`select @have_thread_concurrency = 0`)
|
||||
{
|
||||
skip Need @@thread_concurrency;
|
||||
}
|
||||
enable_result_log;
|
||||
enable_query_log;
|
||||
@@ -1,13 +1,20 @@
|
||||
#
|
||||
# Check if server has support for loading udf's
|
||||
# i.e it will support dlopen
|
||||
# Check if server has support for loading plugins
|
||||
#
|
||||
--source include/have_dynamic_loading.inc
|
||||
if (`SELECT @@have_dynamic_loading != 'YES'`) {
|
||||
--skip UDF requires dynamic loading
|
||||
}
|
||||
|
||||
#
|
||||
# Check if the variable UDF_EXAMPLE_LIB is set
|
||||
#
|
||||
--require r/have_udf_example.require
|
||||
disable_query_log;
|
||||
eval select LENGTH('$UDF_EXAMPLE_LIB') > 0 as 'have_udf_example_lib';
|
||||
enable_query_log;
|
||||
if (`SELECT LENGTH('$UDF_EXAMPLE_LIB') = 0`) {
|
||||
--skip UDF requires the environment variable \$UDF_EXAMPLE_LIB to be set (normally done by mtr)
|
||||
}
|
||||
|
||||
#
|
||||
# Check if --plugin-dir was setup for udf
|
||||
#
|
||||
if (`SELECT CONCAT('--plugin-dir=', @@plugin_dir) != '$UDF_EXAMPLE_LIB_OPT'`) {
|
||||
--skip UDF requires that --plugin-dir is set to the udf plugin dir (either the .opt file does not contain \$UDF_EXAMPLE_LIB_OPT or another plugin is in use)
|
||||
}
|
||||
|
||||
@@ -303,7 +303,7 @@ drop table t4;
|
||||
create table t4 (a int);
|
||||
insert into t4 values (1),(4),(3);
|
||||
set @save_join_buffer_size=@@join_buffer_size;
|
||||
set join_buffer_size= 4000;
|
||||
set join_buffer_size= 4096;
|
||||
explain select max(A.key1 + B.key1 + A.key2 + B.key2 + A.key3 + B.key3 + A.key4 + B.key4 + A.key5 + B.key5)
|
||||
from t0 as A force index(i1,i2), t0 as B force index (i1,i2)
|
||||
where (A.key1 < 500000 or A.key2 < 3)
|
||||
|
||||
41
mysql-test/include/mysqld--help.inc
Normal file
41
mysql-test/include/mysqld--help.inc
Normal file
@@ -0,0 +1,41 @@
|
||||
#
|
||||
# mysqld --help
|
||||
#
|
||||
--source include/not_embedded.inc
|
||||
|
||||
#
|
||||
# force lower-case-table-names=1 (linux/macosx have different defaults)
|
||||
# force symbolic-links=0 (valgrind build has a different default)
|
||||
#
|
||||
exec $MYSQLD_BOOTSTRAP_CMD --symbolic-links=0 --lower-case-table-names=1 --help --verbose > $MYSQL_TMP_DIR/mysqld--help.txt 2>&1;
|
||||
|
||||
perl;
|
||||
@skipvars=qw/basedir open-files-limit general-log-file log
|
||||
log-slow-queries pid-file slow-query-log-file
|
||||
datadir slave-load-tmpdir tmpdir/;
|
||||
@plugins=qw/innodb ndb ndbcluster safemalloc debug temp-pool ssl des-key-file
|
||||
thread-concurrency super-large-pages mutex-deadlock-detector/;
|
||||
@env=qw/MYSQLTEST_VARDIR MYSQL_TEST_DIR MYSQL_LIBDIR MYSQL_SHAREDIR/;
|
||||
$re1=join('|', @skipvars, @plugins);
|
||||
$re2=join('|', @plugins);
|
||||
$skip=0;
|
||||
open(F, '<', "$ENV{MYSQL_TMP_DIR}/mysqld--help.txt") or die;
|
||||
while (<F>) {
|
||||
next if 1../The following groups are read/;
|
||||
next if /^($re1) /;
|
||||
next if /^($re2)-/;
|
||||
$skip=0 if /^ -/;
|
||||
$skip=1 if / --($re2)\b/;
|
||||
# fixes for 32-bit
|
||||
y!\\!/!;
|
||||
s/\b4294967295\b/18446744073709551615/;
|
||||
s/\b2146435072\b/9223372036853727232/;
|
||||
s/\b196608\b/262144/;
|
||||
foreach $var (@env) { s/$ENV{$var}/$var/ }
|
||||
next if /use --skip-(use-)?symbolic-links to disable/; # for valgrind, again
|
||||
next if $skip;
|
||||
print;
|
||||
}
|
||||
close F;
|
||||
EOF
|
||||
|
||||
@@ -114,7 +114,7 @@ connection default;
|
||||
# This should be 'YES'.
|
||||
SHOW VARIABLES LIKE 'have_query_cache';
|
||||
|
||||
SET GLOBAL query_cache_size = 200000;
|
||||
SET GLOBAL query_cache_size = 204800;
|
||||
flush status;
|
||||
SET @@autocommit=1;
|
||||
eval SET SESSION STORAGE_ENGINE = $engine_type;
|
||||
|
||||
@@ -27,7 +27,7 @@ connect (con1,localhost,root,,test,$MASTER_MYPORT,);
|
||||
connection default;
|
||||
|
||||
set @initial_query_cache_size = @@global.query_cache_size;
|
||||
set @@global.query_cache_size=100000;
|
||||
set @@global.query_cache_size=102400;
|
||||
flush status;
|
||||
--disable_warnings
|
||||
drop table if exists t1;
|
||||
@@ -178,7 +178,7 @@ show status like 'Qcache_hits';
|
||||
# then QC is re-enabled for more EXECUTE.
|
||||
--echo ---- switch to connection default ----
|
||||
connection default;
|
||||
set global query_cache_size=100000;
|
||||
set global query_cache_size=102400;
|
||||
# Expect to see additional Qcache_hits.
|
||||
# The fact that the QC was temporary disabled should have no affect
|
||||
# except that the first execute will not hit results from the
|
||||
@@ -235,7 +235,7 @@ prepare stmt3 from "select * from t1 where c1=10";
|
||||
--echo ---- switch to connection default ----
|
||||
connection default;
|
||||
# then QC is enabled at EXECUTE
|
||||
set global query_cache_size=100000;
|
||||
set global query_cache_size=102400;
|
||||
show status like 'Qcache_hits';
|
||||
execute stmt1;
|
||||
show status like 'Qcache_hits';
|
||||
@@ -260,7 +260,7 @@ connection default;
|
||||
set global query_cache_size=0;
|
||||
prepare stmt1 from "select * from t1 where c1=?";
|
||||
# then QC is enabled at EXECUTE
|
||||
set global query_cache_size=100000;
|
||||
set global query_cache_size=102400;
|
||||
show status like 'Qcache_hits';
|
||||
set @a=1;
|
||||
execute stmt1 using @a;
|
||||
@@ -509,7 +509,7 @@ execute stmt;
|
||||
set @@global.query_cache_size=0;
|
||||
alter table t1 add column b int;
|
||||
execute stmt;
|
||||
set @@global.query_cache_size=100000;
|
||||
set @@global.query_cache_size=102400;
|
||||
execute stmt;
|
||||
execute stmt;
|
||||
--echo #
|
||||
|
||||
@@ -55,11 +55,13 @@ connection master;
|
||||
--echo "Running on the master"
|
||||
--enable_info
|
||||
eval CREATE TABLE t1(sum INT, price FLOAT(24)) ENGINE=$engine_type;
|
||||
--disable_warnings
|
||||
INSERT INTO t1 VALUES(myfunc_int(100), myfunc_double(50.00));
|
||||
INSERT INTO t1 VALUES(myfunc_int(10), myfunc_double(5.00));
|
||||
INSERT INTO t1 VALUES(myfunc_int(200), myfunc_double(25.00));
|
||||
INSERT INTO t1 VALUES(myfunc_int(1), myfunc_double(500.00));
|
||||
SELECT * FROM t1 ORDER BY sum;
|
||||
--enable_warnings
|
||||
--disable_info
|
||||
|
||||
sync_slave_with_master;
|
||||
|
||||
@@ -3,6 +3,6 @@
|
||||
|
||||
# masked out log positions
|
||||
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT $DEFAULT_MASTER_PORT 3306
|
||||
--replace_column 1 # 7 # 8 # 9 # 16 # 22 # 23 # 33 # 35 # 36 #
|
||||
query_vertical SHOW SLAVE STATUS;
|
||||
|
||||
@@ -3911,7 +3911,7 @@ sub mysqld_arguments ($$$$) {
|
||||
|
||||
if ( $opt_valgrind_mysqld )
|
||||
{
|
||||
mtr_add_arg($args, "%s--skip-safemalloc", $prefix);
|
||||
mtr_add_arg($args, "%s--loose-skip-safemalloc", $prefix);
|
||||
|
||||
if ( $mysql_version_id < 50100 )
|
||||
{
|
||||
@@ -5208,7 +5208,6 @@ sub valgrind_arguments {
|
||||
else
|
||||
{
|
||||
mtr_add_arg($args, "--tool=memcheck"); # From >= 2.1.2 needs this option
|
||||
mtr_add_arg($args, "--alignment=8");
|
||||
mtr_add_arg($args, "--leak-check=yes");
|
||||
mtr_add_arg($args, "--num-callers=16");
|
||||
mtr_add_arg($args, "--suppressions=%s/valgrind.supp", $glob_mysql_test_dir)
|
||||
|
||||
@@ -1,6 +1,21 @@
|
||||
#!/usr/bin/perl
|
||||
# -*- cperl -*-
|
||||
|
||||
# Copyright (C) 2009 Sun Microsystems, Inc
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
#
|
||||
##############################################################################
|
||||
#
|
||||
@@ -68,8 +83,8 @@ use My::File::Path; # Patched version of File::Path
|
||||
use File::Basename;
|
||||
use File::Copy;
|
||||
use File::Find;
|
||||
use File::Temp qw /tempdir/;
|
||||
use File::Spec::Functions qw / splitdir /;
|
||||
use File::Temp qw/tempdir/;
|
||||
use File::Spec::Functions qw/splitdir/;
|
||||
use My::Platform;
|
||||
use My::SafeProcess;
|
||||
use My::ConfigFactory;
|
||||
@@ -118,6 +133,8 @@ END {
|
||||
}
|
||||
}
|
||||
|
||||
sub env_or_val($$) { defined $ENV{$_[0]} ? $ENV{$_[0]} : $_[1] }
|
||||
|
||||
my $path_config_file; # The generated config file, var/my.cnf
|
||||
|
||||
# Visual Studio produces executables in different sub-directories based on the
|
||||
@@ -126,7 +143,9 @@ my $path_config_file; # The generated config file, var/my.cnf
|
||||
# executables will be used by the test suite.
|
||||
our $opt_vs_config = $ENV{'MTR_VS_CONFIG'};
|
||||
|
||||
my $DEFAULT_SUITES= "main,binlog,federated,rpl,rpl_ndb,ndb,innodb";
|
||||
# If you add a new suite, please check TEST_DIRS in Makefile.am.
|
||||
#
|
||||
my $DEFAULT_SUITES= "main,sys_vars,binlog,federated,rpl,rpl_ndb,ndb,innodb,perfschema";
|
||||
my $opt_suites;
|
||||
|
||||
our $opt_verbose= 0; # Verbose output, enable with --verbose
|
||||
@@ -213,7 +232,7 @@ my $start_only;
|
||||
my $opt_wait_all;
|
||||
my $opt_repeat= 1;
|
||||
my $opt_retry= 3;
|
||||
my $opt_retry_failure= 2;
|
||||
my $opt_retry_failure= env_or_val(MTR_RETRY_FAILURE => 2);
|
||||
|
||||
my $opt_strace_client;
|
||||
|
||||
@@ -242,9 +261,9 @@ our %mysqld_variables;
|
||||
|
||||
my $source_dist= 0;
|
||||
|
||||
my $opt_max_save_core= $ENV{MTR_MAX_SAVE_CORE} || 5;
|
||||
my $opt_max_save_datadir= $ENV{MTR_MAX_SAVE_DATADIR} || 20;
|
||||
my $opt_max_test_fail= $ENV{MTR_MAX_TEST_FAIL} || 10;
|
||||
my $opt_max_save_core= env_or_val(MTR_MAX_SAVE_CORE => 5);
|
||||
my $opt_max_save_datadir= env_or_val(MTR_MAX_SAVE_DATADIR => 20);
|
||||
my $opt_max_test_fail= env_or_val(MTR_MAX_TEST_FAIL => 10);
|
||||
|
||||
my $opt_parallel= $ENV{MTR_PARALLEL} || 1;
|
||||
|
||||
@@ -783,11 +802,12 @@ sub set_vardir {
|
||||
sub command_line_setup {
|
||||
my $opt_comment;
|
||||
my $opt_usage;
|
||||
my $opt_list_options;
|
||||
|
||||
# Read the command line options
|
||||
# Note: Keep list, and the order, in sync with usage at end of this file
|
||||
Getopt::Long::Configure("pass_through");
|
||||
GetOptions(
|
||||
my %options=(
|
||||
# Control what engine/variation to run
|
||||
'embedded-server' => \$opt_embedded_server,
|
||||
'ps-protocol' => \$opt_ps_protocol,
|
||||
@@ -905,9 +925,13 @@ sub command_line_setup {
|
||||
'timediff' => \&report_option,
|
||||
|
||||
'help|h' => \$opt_usage,
|
||||
) or usage("Can't read options");
|
||||
'list-options' => \$opt_list_options,
|
||||
);
|
||||
|
||||
GetOptions(%options) or usage("Can't read options");
|
||||
|
||||
usage("") if $opt_usage;
|
||||
list_options(\%options) if $opt_list_options;
|
||||
|
||||
# --------------------------------------------------------------------------
|
||||
# Setup verbosity
|
||||
@@ -1925,7 +1949,6 @@ sub environment_setup {
|
||||
split(':', $ENV{'LIBPATH'}) : ());
|
||||
mtr_debug("LIBPATH: $ENV{'LIBPATH'}");
|
||||
|
||||
$ENV{'CHARSETSDIR'}= $path_charsetsdir;
|
||||
$ENV{'UMASK'}= "0660"; # The octal *string*
|
||||
$ENV{'UMASK_DIR'}= "0770"; # The octal *string*
|
||||
|
||||
@@ -1943,9 +1966,11 @@ sub environment_setup {
|
||||
$ENV{'LC_COLLATE'}= "C";
|
||||
$ENV{'USE_RUNNING_SERVER'}= using_extern();
|
||||
$ENV{'MYSQL_TEST_DIR'}= $glob_mysql_test_dir;
|
||||
$ENV{'DEFAULT_MASTER_PORT'}= $mysqld_variables{'master-port'} || 3306;
|
||||
$ENV{'DEFAULT_MASTER_PORT'}= $mysqld_variables{'port'};
|
||||
$ENV{'MYSQL_TMP_DIR'}= $opt_tmpdir;
|
||||
$ENV{'MYSQLTEST_VARDIR'}= $opt_vardir;
|
||||
$ENV{'MYSQL_LIBDIR'}= "$basedir/lib";
|
||||
$ENV{'MYSQL_SHAREDIR'}= $path_language;
|
||||
|
||||
# ----------------------------------------------------
|
||||
# Setup env for NDB
|
||||
@@ -3784,7 +3809,7 @@ sub start_check_warnings ($$) {
|
||||
mtr_add_arg($args, "--defaults-file=%s", $path_config_file);
|
||||
mtr_add_arg($args, "--defaults-group-suffix=%s", $mysqld->after('mysqld'));
|
||||
|
||||
mtr_add_arg($args, "--skip-safemalloc");
|
||||
mtr_add_arg($args, "--loose-skip-safemalloc");
|
||||
mtr_add_arg($args, "--test-file=%s", "include/check-warnings.test");
|
||||
mtr_add_arg($args, "--verbose");
|
||||
|
||||
@@ -4208,7 +4233,7 @@ sub mysqld_arguments ($$$) {
|
||||
|
||||
if ( $opt_valgrind_mysqld )
|
||||
{
|
||||
mtr_add_arg($args, "--skip-safemalloc");
|
||||
mtr_add_arg($args, "--loose-skip-safemalloc");
|
||||
|
||||
if ( $mysql_version_id < 50100 )
|
||||
{
|
||||
@@ -4993,7 +5018,7 @@ sub gdb_arguments {
|
||||
my $type= shift;
|
||||
|
||||
# Write $args to gdb init file
|
||||
my $str= join(" ", @$$args);
|
||||
my $str= join " ", map { s/"/\\"/g; "\"$_\""; } @$$args;
|
||||
my $gdb_init_file= "$opt_vardir/tmp/gdbinit.$type";
|
||||
|
||||
# Remove the old gdbinit file
|
||||
@@ -5057,7 +5082,7 @@ sub ddd_arguments {
|
||||
my $type= shift;
|
||||
|
||||
# Write $args to ddd init file
|
||||
my $str= join(" ", @$$args);
|
||||
my $str= join " ", map { s/"/\\"/g; "\"$_\""; } @$$args;
|
||||
my $gdb_init_file= "$opt_vardir/tmp/gdbinit.$type";
|
||||
|
||||
# Remove the old gdbinit file
|
||||
@@ -5122,8 +5147,8 @@ sub debugger_arguments {
|
||||
# vc[express] /debugexe exe arg1 .. argn
|
||||
|
||||
# Add /debugexe and name of the exe before args
|
||||
unshift(@$$args, "/debugexe");
|
||||
unshift(@$$args, "$$exe");
|
||||
unshift(@$$args, "/debugexe");
|
||||
|
||||
# Set exe to debuggername
|
||||
$$exe= $debugger;
|
||||
@@ -5392,3 +5417,15 @@ HERE
|
||||
|
||||
}
|
||||
|
||||
sub list_options ($) {
|
||||
my $hash= shift;
|
||||
|
||||
for (keys %$hash) {
|
||||
s/([:=].*|[+!])$//;
|
||||
s/\|/\n--/g;
|
||||
print "--$_\n" unless /list-options/;
|
||||
}
|
||||
|
||||
exit(1);
|
||||
}
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@ Database
|
||||
information_schema
|
||||
mtr
|
||||
mysql
|
||||
performance_schema
|
||||
test
|
||||
show tables in mysql;
|
||||
Tables_in_mysql
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||
DROP TABLE if exists t1,t2,t3,t4,t5,t6;
|
||||
SET storage_engine=ARCHIVE;
|
||||
CREATE TABLE t1 (
|
||||
@@ -12707,7 +12708,7 @@ DATA_LENGTH AVG_ROW_LENGTH
|
||||
8700 4350
|
||||
DROP TABLE t1;
|
||||
SET @save_join_buffer_size= @@join_buffer_size;
|
||||
SET @@join_buffer_size= 8228;
|
||||
SET @@join_buffer_size= 8192;
|
||||
CREATE TABLE t1(a CHAR(255)) ENGINE=archive;
|
||||
INSERT INTO t1 VALUES('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'),
|
||||
('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'),
|
||||
|
||||
@@ -266,7 +266,7 @@ fid AsText(EndPoint(g))
|
||||
107 POINT(40 10)
|
||||
SELECT fid, GLength(g) FROM gis_line ORDER by fid;
|
||||
fid GLength(g)
|
||||
105 24.142135623731
|
||||
105 24.14213562373095
|
||||
106 40
|
||||
107 30
|
||||
SELECT fid, NumPoints(g) FROM gis_line ORDER by fid;
|
||||
@@ -292,7 +292,7 @@ Note 1003 select astext(startpoint(`test`.`gis_line`.`g`)) AS `AsText(StartPoint
|
||||
SELECT fid, AsText(Centroid(g)) FROM gis_polygon ORDER by fid;
|
||||
fid AsText(Centroid(g))
|
||||
108 POINT(15 15)
|
||||
109 POINT(25.4166666666667 25.4166666666667)
|
||||
109 POINT(25.416666666666668 25.416666666666668)
|
||||
110 POINT(20 10)
|
||||
SELECT fid, Area(g) FROM gis_polygon ORDER by fid;
|
||||
fid Area(g)
|
||||
@@ -326,8 +326,8 @@ fid IsClosed(g)
|
||||
116 0
|
||||
SELECT fid, AsText(Centroid(g)) FROM gis_multi_polygon ORDER by fid;
|
||||
fid AsText(Centroid(g))
|
||||
117 POINT(55.5885277530424 17.426536064114)
|
||||
118 POINT(55.5885277530424 17.426536064114)
|
||||
117 POINT(55.58852775304245 17.426536064113982)
|
||||
118 POINT(55.58852775304245 17.426536064113982)
|
||||
119 POINT(2 2)
|
||||
SELECT fid, Area(g) FROM gis_multi_polygon ORDER by fid;
|
||||
fid Area(g)
|
||||
|
||||
@@ -8,6 +8,8 @@ CREATE TABLE t1(a CHAR(255));
|
||||
INSERT INTO t1 VALUES ('a');
|
||||
SET @@SESSION.sort_buffer_size=5*16*1000000;
|
||||
SET @@SESSION.max_heap_table_size=5*1000000;
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect max_heap_table_size value: '5000000'
|
||||
# Must not crash.
|
||||
SELECT GROUP_CONCAT(a ORDER BY a) FROM t1 GROUP BY a;
|
||||
DROP TABLE t1;
|
||||
|
||||
@@ -134,7 +134,7 @@ connection default
|
||||
SHOW VARIABLES LIKE 'have_query_cache';
|
||||
Variable_name Value
|
||||
have_query_cache YES
|
||||
SET GLOBAL query_cache_size = 200000;
|
||||
SET GLOBAL query_cache_size = 204800;
|
||||
flush status;
|
||||
SET @@autocommit=1;
|
||||
SET SESSION STORAGE_ENGINE = InnoDB;
|
||||
|
||||
@@ -342,11 +342,11 @@ INSERT INTO t1 SET f1 = -1.0e+30 ;
|
||||
INSERT INTO t1 SET f1 = +1.0e+30 ;
|
||||
SELECT f1 AS double_val, CAST(f1 AS SIGNED INT) AS cast_val FROM t1;
|
||||
double_val cast_val
|
||||
-1e+30 -9223372036854775808
|
||||
1e+30 9223372036854775807
|
||||
-1e30 -9223372036854775808
|
||||
1e30 9223372036854775807
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect INTEGER value: '-1e+30'
|
||||
Warning 1292 Truncated incorrect INTEGER value: '1e+30'
|
||||
Warning 1292 Truncated incorrect INTEGER value: '-1e30'
|
||||
Warning 1292 Truncated incorrect INTEGER value: '1e30'
|
||||
DROP TABLE t1;
|
||||
select isnull(date(NULL)), isnull(cast(NULL as DATE));
|
||||
isnull(date(NULL)) isnull(cast(NULL as DATE))
|
||||
@@ -363,7 +363,7 @@ cast('1.2' as decimal(3,2))
|
||||
1.20
|
||||
select 1e18 * cast('1.2' as decimal(3,2));
|
||||
1e18 * cast('1.2' as decimal(3,2))
|
||||
1.2e+18
|
||||
1.2e18
|
||||
select cast(cast('1.2' as decimal(3,2)) as signed);
|
||||
cast(cast('1.2' as decimal(3,2)) as signed)
|
||||
1
|
||||
|
||||
@@ -18,7 +18,7 @@ change_user
|
||||
SELECT @@session.sql_big_selects;
|
||||
@@session.sql_big_selects
|
||||
0
|
||||
SET @@global.max_join_size = -1;
|
||||
SET @@global.max_join_size = 18446744073709551615;
|
||||
SET @@session.max_join_size = default;
|
||||
change_user
|
||||
SELECT @@session.sql_big_selects;
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||
set sql_mode=no_engine_substitution;
|
||||
set storage_engine = InnoDB;
|
||||
set autocommit=1;
|
||||
@@ -578,11 +579,11 @@ SUCCESS
|
||||
select f1();
|
||||
f1()
|
||||
2
|
||||
call p_verify_status_increment(0, 0, 1, 0);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
SUCCESS
|
||||
|
||||
commit;
|
||||
call p_verify_status_increment(0, 0, 1, 0);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
SUCCESS
|
||||
|
||||
# 17. Read-only statement, a function changes non-trans-table.
|
||||
@@ -595,11 +596,11 @@ select f1() from t1;
|
||||
f1()
|
||||
2
|
||||
2
|
||||
call p_verify_status_increment(1, 0, 2, 0);
|
||||
call p_verify_status_increment(2, 0, 2, 0);
|
||||
SUCCESS
|
||||
|
||||
commit;
|
||||
call p_verify_status_increment(1, 0, 2, 0);
|
||||
call p_verify_status_increment(2, 0, 2, 0);
|
||||
SUCCESS
|
||||
|
||||
# 18. Read-write statement: UPDATE, change 0 (transactional) rows.
|
||||
@@ -627,7 +628,7 @@ SUCCESS
|
||||
drop table t2;
|
||||
set sql_mode=no_engine_substitution;
|
||||
create temporary table t2 (a int);
|
||||
call p_verify_status_increment(0, 0, 0, 0);
|
||||
call p_verify_status_increment(1, 0, 0, 0);
|
||||
SUCCESS
|
||||
|
||||
set sql_mode=default;
|
||||
@@ -708,11 +709,11 @@ SUCCESS
|
||||
# 25. DDL: DROP TEMPORARY TABLE, does not start a transaction
|
||||
#
|
||||
drop temporary table t2;
|
||||
call p_verify_status_increment(0, 0, 0, 0);
|
||||
call p_verify_status_increment(1, 0, 0, 0);
|
||||
SUCCESS
|
||||
|
||||
commit;
|
||||
call p_verify_status_increment(0, 0, 0, 0);
|
||||
call p_verify_status_increment(1, 0, 0, 0);
|
||||
SUCCESS
|
||||
|
||||
# 26. Verify that SET AUTOCOMMIT issues an implicit commit
|
||||
@@ -829,11 +830,11 @@ create table if not exists t2 (a int) select 6 union select 7;
|
||||
Warnings:
|
||||
Note 1050 Table 't2' already exists
|
||||
# Sic: first commits the statement, and then the transaction.
|
||||
call p_verify_status_increment(4, 4, 4, 4);
|
||||
call p_verify_status_increment(2, 0, 4, 4);
|
||||
SUCCESS
|
||||
|
||||
create table t3 select a from t2;
|
||||
call p_verify_status_increment(4, 4, 4, 4);
|
||||
call p_verify_status_increment(2, 0, 4, 4);
|
||||
SUCCESS
|
||||
|
||||
alter table t3 add column (b int);
|
||||
@@ -841,15 +842,15 @@ call p_verify_status_increment(2, 0, 2, 0);
|
||||
SUCCESS
|
||||
|
||||
alter table t3 rename t4;
|
||||
call p_verify_status_increment(2, 2, 2, 2);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
SUCCESS
|
||||
|
||||
rename table t4 to t3;
|
||||
call p_verify_status_increment(2, 2, 2, 2);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
SUCCESS
|
||||
|
||||
truncate table t3;
|
||||
call p_verify_status_increment(4, 4, 4, 4);
|
||||
call p_verify_status_increment(2, 0, 2, 0);
|
||||
SUCCESS
|
||||
|
||||
create view v1 as select * from t2;
|
||||
|
||||
@@ -228,7 +228,7 @@ t1 CREATE TABLE `t1` (
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
SET SESSION storage_engine="gemini";
|
||||
ERROR 42000: Unknown table engine 'gemini'
|
||||
ERROR 42000: Unknown storage engine 'gemini'
|
||||
SELECT @@storage_engine;
|
||||
@@storage_engine
|
||||
MEMORY
|
||||
@@ -389,7 +389,7 @@ t1 CREATE TABLE `t1` (
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
SET SESSION storage_engine="gemini";
|
||||
ERROR 42000: Unknown table engine 'gemini'
|
||||
ERROR 42000: Unknown storage engine 'gemini'
|
||||
SELECT @@storage_engine;
|
||||
@@storage_engine
|
||||
MEMORY
|
||||
|
||||
@@ -9,11 +9,14 @@ EXECUTE stmt1 USING @var1;
|
||||
show binlog events from <binlog_start>;
|
||||
Log_name Pos Event_type Server_id End_log_pos Info
|
||||
master-bin.000001 # Query # # use `test`; CREATE TABLE t1(f1 blob)
|
||||
master-bin.000001 # Query # # BEGIN
|
||||
master-bin.000001 # Query # # use `test`; INSERT INTO t1 VALUES(0x8300)
|
||||
master-bin.000001 # Query # # COMMIT
|
||||
SELECT HEX(f1) FROM t1;
|
||||
HEX(f1)
|
||||
8300
|
||||
DROP table t1;
|
||||
call mtr.add_suppression('Error in Log_event::read_log_event()');
|
||||
CREATE TABLE t4 (s1 CHAR(50) CHARACTER SET latin1,
|
||||
s2 CHAR(50) CHARACTER SET cp932,
|
||||
d DECIMAL(10,2))|
|
||||
@@ -29,22 +32,27 @@ HEX(s1) HEX(s2) d
|
||||
466F6F2773206120426172 ED40ED41ED42 47.93
|
||||
DROP PROCEDURE bug18293|
|
||||
DROP TABLE t4|
|
||||
SHOW BINLOG EVENTS FROM 371|
|
||||
SHOW BINLOG EVENTS FROM 514|
|
||||
Log_name Pos Event_type Server_id End_log_pos Info
|
||||
master-bin.000001 371 Query 1 537 use `test`; CREATE TABLE t4 (s1 CHAR(50) CHARACTER SET latin1,
|
||||
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 788 Query 1 856 COMMIT
|
||||
master-bin.000001 856 Query 1 1019 use `test`; CREATE TABLE t4 (s1 CHAR(50) CHARACTER SET latin1,
|
||||
s2 CHAR(50) CHARACTER SET cp932,
|
||||
d DECIMAL(10,2))
|
||||
master-bin.000001 537 Query 1 786 use `test`; CREATE DEFINER=`root`@`localhost` PROCEDURE `bug18293`(IN ins1 CHAR(50),
|
||||
master-bin.000001 1019 Query 1 1265 use `test`; CREATE DEFINER=`root`@`localhost` PROCEDURE `bug18293`(IN ins1 CHAR(50),
|
||||
IN ins2 CHAR(50) CHARACTER SET cp932,
|
||||
IN ind DECIMAL(10,2))
|
||||
BEGIN
|
||||
INSERT INTO t4 VALUES (ins1, ins2, ind);
|
||||
END
|
||||
master-bin.000001 786 Query 1 1050 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 1050 Query 1 1139 use `test`; DROP PROCEDURE bug18293
|
||||
master-bin.000001 1139 Query 1 1218 use `test`; DROP TABLE t4
|
||||
master-bin.000001 1265 Query 1 1333 BEGIN
|
||||
master-bin.000001 1333 Query 1 1597 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 1597 Query 1 1666 COMMIT
|
||||
master-bin.000001 1666 Query 1 1752 use `test`; DROP PROCEDURE bug18293
|
||||
master-bin.000001 1752 Query 1 1828 use `test`; DROP TABLE t4
|
||||
End of 5.0 tests
|
||||
SHOW BINLOG EVENTS FROM 366;
|
||||
SHOW BINLOG EVENTS FROM 490;
|
||||
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Wrong offset or I/O error
|
||||
Bug#44352 UPPER/LOWER function doesn't work correctly on cp932 and sjis environment.
|
||||
CREATE TABLE t1 (a varchar(16)) character set cp932;
|
||||
|
||||
@@ -15,71 +15,6 @@ variable_name variable_value
|
||||
DATETIME_FORMAT %Y-%m-%d %H:%i:%s
|
||||
DATE_FORMAT %d.%m.%Y
|
||||
TIME_FORMAT %H.%i.%s
|
||||
SET time_format='%H%i%s';
|
||||
SET time_format='%H:%i:%s.%f';
|
||||
SET time_format='%h-%i-%s.%f%p';
|
||||
SET time_format='%h:%i:%s.%f %p';
|
||||
SET time_format='%h:%i:%s%p';
|
||||
SET date_format='%Y%m%d';
|
||||
SET date_format='%Y.%m.%d';
|
||||
SET date_format='%d.%m.%Y';
|
||||
SET date_format='%m-%d-%Y';
|
||||
set datetime_format= '%Y%m%d%H%i%s';
|
||||
set datetime_format= '%Y-%m-%d %H:%i:%s';
|
||||
set datetime_format= '%m-%d-%y %H:%i:%s.%f';
|
||||
set datetime_format= '%d-%m-%Y %h:%i:%s%p';
|
||||
set datetime_format= '%H:%i:%s %Y-%m-%d';
|
||||
set datetime_format= '%H:%i:%s.%f %m-%d-%Y';
|
||||
set datetime_format= '%h:%i:%s %p %Y-%m-%d';
|
||||
set datetime_format= '%h:%i:%s.%f %p %Y-%m-%d';
|
||||
SELECT variable_name, variable_value
|
||||
FROM information_schema.session_variables
|
||||
WHERE variable_name IN ('date_format', 'datetime_format', 'time_format')
|
||||
ORDER BY variable_name;
|
||||
variable_name variable_value
|
||||
DATETIME_FORMAT %h:%i:%s.%f %p %Y-%m-%d
|
||||
DATE_FORMAT %m-%d-%Y
|
||||
TIME_FORMAT %h:%i:%s%p
|
||||
SET time_format='%h:%i:%s';
|
||||
ERROR 42000: Variable 'time_format' can't be set to the value of '%h:%i:%s'
|
||||
SET time_format='%H %i:%s';
|
||||
ERROR 42000: Variable 'time_format' can't be set to the value of '%H %i:%s'
|
||||
SET time_format='%H::%i:%s';
|
||||
ERROR 42000: Variable 'time_format' can't be set to the value of '%H::%i:%s'
|
||||
SET time_format='%H:%i:%s%f';
|
||||
ERROR 42000: Variable 'time_format' can't be set to the value of '%H:%i:%s%f'
|
||||
SET time_format='%H:%i.%f:%s';
|
||||
ERROR 42000: Variable 'time_format' can't be set to the value of '%H:%i.%f:%s'
|
||||
SET time_format='%H:%i:%s%p';
|
||||
ERROR 42000: Variable 'time_format' can't be set to the value of '%H:%i:%s%p'
|
||||
SET time_format='%h:%i:%s.%f %p %Y-%m-%d';
|
||||
ERROR 42000: Variable 'time_format' can't be set to the value of '%h:%i:%s.%f %p %Y-%m-%d'
|
||||
SET time_format='%H%i%s.%f';
|
||||
ERROR 42000: Variable 'time_format' can't be set to the value of '%H%i%s.%f'
|
||||
SET time_format='%H:%i-%s.%f';
|
||||
ERROR 42000: Variable 'time_format' can't be set to the value of '%H:%i-%s.%f'
|
||||
SET date_format='%d.%m.%d';
|
||||
ERROR 42000: Variable 'date_format' can't be set to the value of '%d.%m.%d'
|
||||
SET datetime_format='%h.%m.%y %d.%i.%s';
|
||||
ERROR 42000: Variable 'datetime_format' can't be set to the value of '%h.%m.%y %d.%i.%s'
|
||||
set datetime_format= '%H:%i:%s.%f %p %Y-%m-%d';
|
||||
ERROR 42000: Variable 'datetime_format' can't be set to the value of '%H:%i:%s.%f %p %Y-%m-%d'
|
||||
set GLOBAL datetime_format= '%H:%i:%s %Y-%m-%d';
|
||||
SET SESSION datetime_format=default;
|
||||
select @@global.datetime_format, @@session.datetime_format;
|
||||
@@global.datetime_format @@session.datetime_format
|
||||
%H:%i:%s %Y-%m-%d %H:%i:%s %Y-%m-%d
|
||||
SET GLOBAL datetime_format=default;
|
||||
SET SESSION datetime_format=default;
|
||||
select @@global.datetime_format, @@session.datetime_format;
|
||||
@@global.datetime_format @@session.datetime_format
|
||||
%Y-%m-%d %H:%i:%s %Y-%m-%d %H:%i:%s
|
||||
SET GLOBAL date_format=default;
|
||||
SET GLOBAL time_format=default;
|
||||
SET GLOBAL datetime_format=default;
|
||||
SET time_format=default;
|
||||
SET date_format=default;
|
||||
SET datetime_format=default;
|
||||
select str_to_date(concat('15-01-2001',' 2:59:58.999'),
|
||||
concat('%d-%m-%Y',' ','%H:%i:%s.%f'));
|
||||
str_to_date(concat('15-01-2001',' 2:59:58.999'),
|
||||
|
||||
@@ -50,6 +50,7 @@ information_schema
|
||||
mtr
|
||||
mysql
|
||||
mysqltest
|
||||
performance_schema
|
||||
test
|
||||
flush tables with read lock;
|
||||
drop database mysqltest;
|
||||
@@ -61,6 +62,7 @@ Database
|
||||
information_schema
|
||||
mtr
|
||||
mysql
|
||||
performance_schema
|
||||
test
|
||||
drop database mysqltest;
|
||||
ERROR HY000: Can't drop database 'mysqltest'; database doesn't exist
|
||||
|
||||
@@ -109,10 +109,10 @@ SET sql_quote_show_create= _utf8 x'5452C39C45';
|
||||
ERROR 42000: Variable 'sql_quote_show_create' can't be set to the value of 'TR<54>E'
|
||||
SET sql_quote_show_create=_latin1 x'5452DC45';
|
||||
ERROR 42000: Variable 'sql_quote_show_create' can't be set to the value of 'TR<54>E'
|
||||
SET sql_quote_show_create='TR.E';
|
||||
ERROR 42000: Variable 'sql_quote_show_create' can't be set to the value of 'TR.E'
|
||||
SET sql_quote_show_create=TR.E;
|
||||
ERROR 42000: Variable 'sql_quote_show_create' can't be set to the value of 'E'
|
||||
SET sql_quote_show_create='TR<EFBFBD>E';
|
||||
ERROR 42000: Variable 'sql_quote_show_create' can't be set to the value of 'TR<EFBFBD>E'
|
||||
SET sql_quote_show_create=TR<EFBFBD>E;
|
||||
ERROR 42000: Variable 'sql_quote_show_create' can't be set to the value of 'TR<EFBFBD>E'
|
||||
SET NAMES binary;
|
||||
SET sql_quote_show_create= _binary x'5452C39C45';
|
||||
ERROR 42000: Variable 'sql_quote_show_create' can't be set to the value of 'TR\xC3\x9CE'
|
||||
|
||||
@@ -13,12 +13,6 @@ ERROR HY000: Incorrect AT value: 'definitely not a datetime'
|
||||
set names utf8;
|
||||
create event задачка on schedule every 123 minute starts now() ends now() + interval 1 month do select 1;
|
||||
drop event задачка;
|
||||
set event_scheduler=off;
|
||||
ERROR HY000: Variable 'event_scheduler' is a GLOBAL variable and should be set with SET GLOBAL
|
||||
set global event_scheduler=3;
|
||||
ERROR 42000: Variable 'event_scheduler' can't be set to the value of '3'
|
||||
set global event_scheduler=disabled;
|
||||
ERROR 42000: Variable 'event_scheduler' can't be set to the value of 'disabled'
|
||||
"DISABLE the scheduler. Testing that it does not work when the variable is 0"
|
||||
set global event_scheduler=off;
|
||||
select definer, name, db from mysql.event;
|
||||
|
||||
@@ -725,16 +725,15 @@ DROP USER mysqltest_u1@localhost;
|
||||
|
||||
drop procedure if exists p;
|
||||
set @old_mode= @@sql_mode;
|
||||
set @@sql_mode= pow(2,32)-1;
|
||||
set @@sql_mode= cast(pow(2,32)-1 as unsigned integer);
|
||||
create event e1 on schedule every 1 day do select 1;
|
||||
select @@sql_mode;
|
||||
@@sql_mode
|
||||
REAL_AS_FLOAT,PIPES_AS_CONCAT,ANSI_QUOTES,IGNORE_SPACE,?,ONLY_FULL_GROUP_BY,NO_UNSIGNED_SUBTRACTION,NO_DIR_IN_CREATE,POSTGRESQL,ORACLE,MSSQL,DB2,MAXDB,NO_KEY_OPTIONS,NO_TABLE_OPTIONS,NO_FIELD_OPTIONS,MYSQL323,MYSQL40,ANSI,NO_AUTO_VALUE_ON_ZERO,NO_BACKSLASH_ESCAPES,STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ALLOW_INVALID_DATES,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_AUTO_CREATE_USER,HIGH_NOT_PRECEDENCE,NO_ENGINE_SUBSTITUTION,PAD_CHAR_TO_FULL_LENGTH
|
||||
select @@sql_mode into @full_mode;
|
||||
set @@sql_mode= @old_mode;
|
||||
select replace(@full_mode, '?', 'NOT_USED') into @full_mode;
|
||||
select replace(@full_mode, ',,,', ',NOT_USED,') into @full_mode;
|
||||
select replace(@full_mode, 'ALLOW_INVALID_DATES', 'INVALID_DATES') into @full_mode;
|
||||
select name from mysql.event where name = 'p' and sql_mode = @full_mode;
|
||||
select name from mysql.event where name = 'e1' and sql_mode = @full_mode;
|
||||
name
|
||||
e1
|
||||
drop event e1;
|
||||
SET @old_server_id = @@GLOBAL.server_id;
|
||||
SET GLOBAL server_id = (1 << 32) - 1;
|
||||
|
||||
@@ -82,5 +82,24 @@ DROP TABLE table_1;
|
||||
DROP TABLE table_2;
|
||||
DROP TABLE table_3;
|
||||
DROP TABLE table_4;
|
||||
|
||||
Bug #50087 Interval arithmetic for Event_queue_element is not portable.
|
||||
|
||||
CREATE TABLE t1(a int);
|
||||
CREATE EVENT e1 ON SCHEDULE EVERY 1 MONTH
|
||||
STARTS NOW() - INTERVAL 1 MONTH
|
||||
ENDS NOW() + INTERVAL 2 MONTH
|
||||
ON COMPLETION PRESERVE
|
||||
DO
|
||||
INSERT INTO t1 VALUES (1);
|
||||
CREATE EVENT e2 ON SCHEDULE EVERY 1 MONTH
|
||||
STARTS NOW()
|
||||
ENDS NOW() + INTERVAL 11 MONTH
|
||||
ON COMPLETION PRESERVE
|
||||
DO
|
||||
INSERT INTO t1 VALUES (1);
|
||||
DROP TABLE t1;
|
||||
DROP EVENT e1;
|
||||
DROP EVENT e2;
|
||||
DROP DATABASE events_test;
|
||||
SET GLOBAL event_scheduler=@event_scheduler;
|
||||
|
||||
@@ -61,7 +61,7 @@ grp sum
|
||||
NULL NULL
|
||||
1 7
|
||||
2 20.25
|
||||
3 45.4831632475944
|
||||
3 45.48316324759439
|
||||
create table t2 (grp int, a bigint unsigned, c char(10));
|
||||
insert into t2 select grp,max(a)+max(grp),max(c) from t1 group by grp;
|
||||
replace into t2 select grp, a, c from t1 limit 2,1;
|
||||
@@ -891,7 +891,7 @@ select 1e8 * sum(distinct df) from t1;
|
||||
330000000
|
||||
select 1e8 * min(df) from t1;
|
||||
1e8 * min(df)
|
||||
110000000
|
||||
110000000.00000001
|
||||
create table t3 (ifl int);
|
||||
insert into t3 values(1), (2);
|
||||
select cast(min(ifl) as decimal(5,2)) from t3;
|
||||
@@ -1186,7 +1186,7 @@ std(s1/s2)
|
||||
0.21325764
|
||||
select std(o1/o2) from bug22555;
|
||||
std(o1/o2)
|
||||
0.213257635866493
|
||||
0.2132576358664934
|
||||
select std(e1/e2) from bug22555;
|
||||
std(e1/e2)
|
||||
0.21325764
|
||||
@@ -1209,13 +1209,13 @@ i count(*) std(e1/e2)
|
||||
3 4 0.000000000000000000000000000000
|
||||
select round(std(s1/s2), 17) from bug22555;
|
||||
round(std(s1/s2), 17)
|
||||
0.21325763586649341
|
||||
0.21325763586649340
|
||||
select std(o1/o2) from bug22555;
|
||||
std(o1/o2)
|
||||
0.213257635866493
|
||||
0.2132576358664934
|
||||
select round(std(e1/e2), 17) from bug22555;
|
||||
round(std(e1/e2), 17)
|
||||
0.21325763586649341
|
||||
0.21325763586649340
|
||||
set div_precision_increment=20;
|
||||
select i, count(*), std(s1/s2) from bug22555 group by i order by i;
|
||||
i count(*) std(s1/s2)
|
||||
@@ -1234,13 +1234,13 @@ i count(*) std(e1/e2)
|
||||
3 4 0.000000000000000000000000000000
|
||||
select round(std(s1/s2), 17) from bug22555;
|
||||
round(std(s1/s2), 17)
|
||||
0.21325763586649341
|
||||
0.21325763586649340
|
||||
select std(o1/o2) from bug22555;
|
||||
std(o1/o2)
|
||||
0.213257635866493
|
||||
0.2132576358664934
|
||||
select round(std(e1/e2), 17) from bug22555;
|
||||
round(std(e1/e2), 17)
|
||||
0.21325763586649341
|
||||
0.21325763586649340
|
||||
set @@div_precision_increment=@saved_div_precision_increment;
|
||||
drop table bug22555;
|
||||
create table bug22555 (s smallint, o double, e decimal);
|
||||
|
||||
@@ -44,7 +44,7 @@ Warnings:
|
||||
Note 1003 select abs(-(10)) AS `abs(-10)`,sign(-(5)) AS `sign(-5)`,sign(5) AS `sign(5)`,sign(0) AS `sign(0)`
|
||||
select log(exp(10)),exp(log(sqrt(10))*2),log(-1),log(NULL),log(1,1),log(3,9),log(-1,2),log(NULL,2);
|
||||
log(exp(10)) exp(log(sqrt(10))*2) log(-1) log(NULL) log(1,1) log(3,9) log(-1,2) log(NULL,2)
|
||||
10 10 NULL NULL NULL 2 NULL NULL
|
||||
10 10.000000000000002 NULL NULL NULL 2 NULL NULL
|
||||
explain extended select log(exp(10)),exp(log(sqrt(10))*2),log(-1),log(NULL),log(1,1),log(3,9),log(-1,2),log(NULL,2);
|
||||
id select_type table type possible_keys key key_len ref rows filtered Extra
|
||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used
|
||||
@@ -52,7 +52,7 @@ Warnings:
|
||||
Note 1003 select log(exp(10)) AS `log(exp(10))`,exp((log(sqrt(10)) * 2)) AS `exp(log(sqrt(10))*2)`,log(-(1)) AS `log(-1)`,log(NULL) AS `log(NULL)`,log(1,1) AS `log(1,1)`,log(3,9) AS `log(3,9)`,log(-(1),2) AS `log(-1,2)`,log(NULL,2) AS `log(NULL,2)`
|
||||
select ln(exp(10)),exp(ln(sqrt(10))*2),ln(-1),ln(0),ln(NULL);
|
||||
ln(exp(10)) exp(ln(sqrt(10))*2) ln(-1) ln(0) ln(NULL)
|
||||
10 10 NULL NULL NULL
|
||||
10 10.000000000000002 NULL NULL NULL
|
||||
explain extended select ln(exp(10)),exp(ln(sqrt(10))*2),ln(-1),ln(0),ln(NULL);
|
||||
id select_type table type possible_keys key key_len ref rows filtered Extra
|
||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used
|
||||
@@ -60,7 +60,7 @@ Warnings:
|
||||
Note 1003 select ln(exp(10)) AS `ln(exp(10))`,exp((ln(sqrt(10)) * 2)) AS `exp(ln(sqrt(10))*2)`,ln(-(1)) AS `ln(-1)`,ln(0) AS `ln(0)`,ln(NULL) AS `ln(NULL)`
|
||||
select log2(8),log2(15),log2(-2),log2(0),log2(NULL);
|
||||
log2(8) log2(15) log2(-2) log2(0) log2(NULL)
|
||||
3 3.90689059560852 NULL NULL NULL
|
||||
3 3.9068905956085187 NULL NULL NULL
|
||||
explain extended select log2(8),log2(15),log2(-2),log2(0),log2(NULL);
|
||||
id select_type table type possible_keys key key_len ref rows filtered Extra
|
||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used
|
||||
@@ -68,7 +68,7 @@ Warnings:
|
||||
Note 1003 select log2(8) AS `log2(8)`,log2(15) AS `log2(15)`,log2(-(2)) AS `log2(-2)`,log2(0) AS `log2(0)`,log2(NULL) AS `log2(NULL)`
|
||||
select log10(100),log10(18),log10(-4),log10(0),log10(NULL);
|
||||
log10(100) log10(18) log10(-4) log10(0) log10(NULL)
|
||||
2 1.25527250510331 NULL NULL NULL
|
||||
2 1.255272505103306 NULL NULL NULL
|
||||
explain extended select log10(100),log10(18),log10(-4),log10(0),log10(NULL);
|
||||
id select_type table type possible_keys key key_len ref rows filtered Extra
|
||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used
|
||||
@@ -85,7 +85,7 @@ Note 1003 select pow(10,log10(10)) AS `pow(10,log10(10))`,pow(2,4) AS `power(2,4
|
||||
set @@rand_seed1=10000000,@@rand_seed2=1000000;
|
||||
select rand(999999),rand();
|
||||
rand(999999) rand()
|
||||
0.0142313651873091 0.028870999839968
|
||||
0.014231365187309091 0.028870999839968048
|
||||
explain extended select rand(999999),rand();
|
||||
id select_type table type possible_keys key key_len ref rows filtered Extra
|
||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used
|
||||
@@ -101,7 +101,7 @@ Warnings:
|
||||
Note 1003 select pi() AS `pi()`,format(sin((pi() / 2)),6) AS `format(sin(pi()/2),6)`,format(cos((pi() / 2)),6) AS `format(cos(pi()/2),6)`,format(abs(tan(pi())),6) AS `format(abs(tan(pi())),6)`,format((1 / tan(1)),6) AS `format(cot(1),6)`,format(asin(1),6) AS `format(asin(1),6)`,format(acos(0),6) AS `format(acos(0),6)`,format(atan(1),6) AS `format(atan(1),6)`
|
||||
select degrees(pi()),radians(360);
|
||||
degrees(pi()) radians(360)
|
||||
180 6.28318530717959
|
||||
180 6.283185307179586
|
||||
select format(atan(-2, 2), 6);
|
||||
format(atan(-2, 2), 6)
|
||||
-0.785398
|
||||
@@ -119,7 +119,7 @@ ACOS(1.0)
|
||||
0
|
||||
SELECT ASIN(1.0);
|
||||
ASIN(1.0)
|
||||
1.5707963267949
|
||||
1.5707963267948966
|
||||
SELECT ACOS(0.2*5.0);
|
||||
ACOS(0.2*5.0)
|
||||
0
|
||||
@@ -128,10 +128,10 @@ ACOS(0.5*2.0)
|
||||
0
|
||||
SELECT ASIN(0.8+0.2);
|
||||
ASIN(0.8+0.2)
|
||||
1.5707963267949
|
||||
1.5707963267948966
|
||||
SELECT ASIN(1.2-0.2);
|
||||
ASIN(1.2-0.2)
|
||||
1.5707963267949
|
||||
1.5707963267948966
|
||||
select format(4.55, 1), format(4.551, 1);
|
||||
format(4.55, 1) format(4.551, 1)
|
||||
4.6 4.6
|
||||
@@ -368,7 +368,7 @@ mod(5, cast(-2 as unsigned)) mod(5, 18446744073709551614) mod(5, -2)
|
||||
5 5 1
|
||||
select pow(cast(-2 as unsigned), 5), pow(18446744073709551614, 5), pow(-2, 5);
|
||||
pow(cast(-2 as unsigned), 5) pow(18446744073709551614, 5) pow(-2, 5)
|
||||
2.13598703592091e+96 2.13598703592091e+96 -32
|
||||
2.13598703592091e96 2.13598703592091e96 -32
|
||||
CREATE TABLE t1 (a timestamp, b varchar(20), c bit(1));
|
||||
INSERT INTO t1 VALUES('1998-09-23', 'str1', 1), ('2003-03-25', 'str2', 0);
|
||||
SELECT a DIV 900 y FROM t1 GROUP BY y;
|
||||
@@ -437,10 +437,10 @@ a ROUND(a)
|
||||
2.5 2
|
||||
-2.9 -3
|
||||
2.9 3
|
||||
-1e+16 -10000000000000000
|
||||
1e+16 10000000000000000
|
||||
-1e+16 -10000000000000002
|
||||
1e+16 10000000000000002
|
||||
-1e16 -10000000000000000
|
||||
1e16 10000000000000000
|
||||
-1.0000000000000002e16 -10000000000000002
|
||||
1.0000000000000002e16 10000000000000002
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1(f1 LONGTEXT) engine=myisam;
|
||||
INSERT INTO t1 VALUES ('a');
|
||||
@@ -475,16 +475,16 @@ NULL
|
||||
CREATE OR REPLACE VIEW v1 AS SELECT NULL AS a;
|
||||
SELECT RAND(a) FROM v1;
|
||||
RAND(a)
|
||||
0.155220427694936
|
||||
0.15522042769493574
|
||||
DROP VIEW v1;
|
||||
SELECT RAND(a) FROM (SELECT NULL AS a) b;
|
||||
RAND(a)
|
||||
0.155220427694936
|
||||
0.15522042769493574
|
||||
CREATE TABLE t1 (i INT);
|
||||
INSERT INTO t1 VALUES (NULL);
|
||||
SELECT RAND(i) FROM t1;
|
||||
RAND(i)
|
||||
0.155220427694936
|
||||
0.15522042769493574
|
||||
DROP TABLE t1;
|
||||
#
|
||||
select 123456789012345678901234567890.123456789012345678901234567890 div 1 as x;
|
||||
|
||||
@@ -1354,10 +1354,10 @@ cast(rtrim(ltrim(' 20.06 ')) as decimal(19,2))
|
||||
20.06
|
||||
select conv("18383815659218730760",10,10) + 0;
|
||||
conv("18383815659218730760",10,10) + 0
|
||||
1.83838156592187e+19
|
||||
1.838381565921873e19
|
||||
select "18383815659218730760" + 0;
|
||||
"18383815659218730760" + 0
|
||||
1.83838156592187e+19
|
||||
1.838381565921873e19
|
||||
CREATE TABLE t1 (code varchar(10));
|
||||
INSERT INTO t1 VALUES ('a12'), ('A12'), ('a13');
|
||||
SELECT ASCII(code), code FROM t1 WHERE code='A12';
|
||||
|
||||
@@ -258,7 +258,7 @@ fid AsText(EndPoint(g))
|
||||
107 POINT(40 10)
|
||||
SELECT fid, GLength(g) FROM gis_line;
|
||||
fid GLength(g)
|
||||
105 24.142135623731
|
||||
105 24.14213562373095
|
||||
106 40
|
||||
107 30
|
||||
SELECT fid, NumPoints(g) FROM gis_line;
|
||||
@@ -284,7 +284,7 @@ Note 1003 select astext(startpoint(`test`.`gis_line`.`g`)) AS `AsText(StartPoint
|
||||
SELECT fid, AsText(Centroid(g)) FROM gis_polygon;
|
||||
fid AsText(Centroid(g))
|
||||
108 POINT(15 15)
|
||||
109 POINT(25.4166666666667 25.4166666666667)
|
||||
109 POINT(25.416666666666668 25.416666666666668)
|
||||
110 POINT(20 10)
|
||||
SELECT fid, Area(g) FROM gis_polygon;
|
||||
fid Area(g)
|
||||
@@ -318,8 +318,8 @@ fid IsClosed(g)
|
||||
116 0
|
||||
SELECT fid, AsText(Centroid(g)) FROM gis_multi_polygon;
|
||||
fid AsText(Centroid(g))
|
||||
117 POINT(55.5885277530424 17.426536064114)
|
||||
118 POINT(55.5885277530424 17.426536064114)
|
||||
117 POINT(55.58852775304245 17.426536064113982)
|
||||
118 POINT(55.58852775304245 17.426536064113982)
|
||||
119 POINT(2 2)
|
||||
SELECT fid, Area(g) FROM gis_multi_polygon;
|
||||
fid Area(g)
|
||||
@@ -651,11 +651,11 @@ insert into t1 values ('85984',GeomFromText('MULTIPOLYGON(((-115.006363
|
||||
select object_id, geometrytype(geo), ISSIMPLE(GEO), ASTEXT(centroid(geo)) from
|
||||
t1 where object_id=85998;
|
||||
object_id geometrytype(geo) ISSIMPLE(GEO) ASTEXT(centroid(geo))
|
||||
85998 MULTIPOLYGON 0 POINT(115.318773152032 -36.2374728210215)
|
||||
85998 MULTIPOLYGON 0 POINT(115.31877315203187 -36.23747282102153)
|
||||
select object_id, geometrytype(geo), ISSIMPLE(GEO), ASTEXT(centroid(geo)) from
|
||||
t1 where object_id=85984;
|
||||
object_id geometrytype(geo) ISSIMPLE(GEO) ASTEXT(centroid(geo))
|
||||
85984 MULTIPOLYGON 0 POINT(-114.877871869233 36.3310176346905)
|
||||
85984 MULTIPOLYGON 0 POINT(-114.87787186923313 36.33101763469059)
|
||||
drop table t1;
|
||||
create table t1 (fl geometry not null);
|
||||
insert into t1 values (1);
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
Variable_name Value
|
||||
have_dynamic_loading YES
|
||||
@@ -1,2 +0,0 @@
|
||||
have_example_plugin
|
||||
1
|
||||
@@ -1,2 +1,2 @@
|
||||
Variable_name Value
|
||||
have_profiling YES
|
||||
have_profiling YES
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
have_simple_parser
|
||||
1
|
||||
@@ -1,2 +0,0 @@
|
||||
have_udf_example_lib
|
||||
1
|
||||
@@ -341,9 +341,7 @@ drop table t4;
|
||||
create table t4 (a int);
|
||||
insert into t4 values (1),(4),(3);
|
||||
set @save_join_buffer_size=@@join_buffer_size;
|
||||
set join_buffer_size= 4000;
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect join_buffer_size value: '4000'
|
||||
set join_buffer_size= 4096;
|
||||
explain select max(A.key1 + B.key1 + A.key2 + B.key2 + A.key3 + B.key3 + A.key4 + B.key4 + A.key5 + B.key5)
|
||||
from t0 as A force index(i1,i2), t0 as B force index (i1,i2)
|
||||
where (A.key1 < 500000 or A.key2 < 3)
|
||||
@@ -1421,21 +1419,20 @@ drop table t1;
|
||||
#
|
||||
select @@optimizer_switch;
|
||||
@@optimizer_switch
|
||||
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on
|
||||
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
set optimizer_switch='index_merge=off,index_merge_union=off';
|
||||
select @@optimizer_switch;
|
||||
@@optimizer_switch
|
||||
index_merge=off,index_merge_union=off,index_merge_sort_union=on,index_merge_intersection=on
|
||||
index_merge=off,index_merge_union=off,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
set optimizer_switch='index_merge_union=on';
|
||||
select @@optimizer_switch;
|
||||
@@optimizer_switch
|
||||
index_merge=off,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on
|
||||
index_merge=off,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
set optimizer_switch='default,index_merge_sort_union=off';
|
||||
select @@optimizer_switch;
|
||||
@@optimizer_switch
|
||||
index_merge=on,index_merge_union=on,index_merge_sort_union=off,index_merge_intersection=on
|
||||
index_merge=on,index_merge_union=on,index_merge_sort_union=off,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
set optimizer_switch=4;
|
||||
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of '4'
|
||||
set optimizer_switch=NULL;
|
||||
ERROR 42000: Variable 'optimizer_switch' can't be set to the value of 'NULL'
|
||||
set optimizer_switch='default,index_merge';
|
||||
@@ -1460,21 +1457,21 @@ set optimizer_switch=default;
|
||||
set optimizer_switch='index_merge=off,index_merge_union=off,default';
|
||||
select @@optimizer_switch;
|
||||
@@optimizer_switch
|
||||
index_merge=off,index_merge_union=off,index_merge_sort_union=on,index_merge_intersection=on
|
||||
index_merge=off,index_merge_union=off,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
set optimizer_switch=default;
|
||||
select @@global.optimizer_switch;
|
||||
@@global.optimizer_switch
|
||||
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on
|
||||
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
set @@global.optimizer_switch=default;
|
||||
select @@global.optimizer_switch;
|
||||
@@global.optimizer_switch
|
||||
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on
|
||||
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
#
|
||||
# Check index_merge's @@optimizer_switch flags
|
||||
#
|
||||
select @@optimizer_switch;
|
||||
@@optimizer_switch
|
||||
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on
|
||||
index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
create table t0 (a int);
|
||||
insert into t0 values (0),(1),(2),(3),(4),(5),(6),(7),(8),(9);
|
||||
create table t1 (a int, b int, c int, filler char(100),
|
||||
@@ -1584,5 +1581,5 @@ id select_type table type possible_keys key key_len ref rows Extra
|
||||
set optimizer_switch=default;
|
||||
show variables like 'optimizer_switch';
|
||||
Variable_name Value
|
||||
optimizer_switch index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on
|
||||
optimizer_switch index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
drop table t0, t1;
|
||||
|
||||
@@ -11,12 +11,14 @@ select * from information_schema.SCHEMATA where schema_name > 'm';
|
||||
CATALOG_NAME SCHEMA_NAME DEFAULT_CHARACTER_SET_NAME DEFAULT_COLLATION_NAME SQL_PATH
|
||||
def mtr latin1 latin1_swedish_ci NULL
|
||||
def mysql latin1 latin1_swedish_ci NULL
|
||||
def performance_schema utf8 utf8_general_ci NULL
|
||||
def test latin1 latin1_swedish_ci NULL
|
||||
select schema_name from information_schema.schemata;
|
||||
schema_name
|
||||
information_schema
|
||||
mtr
|
||||
mysql
|
||||
performance_schema
|
||||
test
|
||||
show databases like 't%';
|
||||
Database (t%)
|
||||
@@ -26,6 +28,7 @@ Database
|
||||
information_schema
|
||||
mtr
|
||||
mysql
|
||||
performance_schema
|
||||
test
|
||||
show databases where `database` = 't%';
|
||||
Database
|
||||
@@ -363,6 +366,7 @@ c
|
||||
information_schema
|
||||
mtr
|
||||
mysql
|
||||
performance_schema
|
||||
test
|
||||
explain select * from v0;
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
|
||||
@@ -1788,7 +1788,7 @@ Variable_name Value
|
||||
innodb_thread_concurrency 0
|
||||
set global innodb_thread_concurrency=1001;
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect thread_concurrency value: '1001'
|
||||
Warning 1292 Truncated incorrect innodb_thread_concurrency value: '1001'
|
||||
show variables like "innodb_thread_concurrency";
|
||||
Variable_name Value
|
||||
innodb_thread_concurrency 1000
|
||||
@@ -1809,7 +1809,7 @@ Variable_name Value
|
||||
innodb_concurrency_tickets 1000
|
||||
set global innodb_concurrency_tickets=0;
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect concurrency_tickets value: '0'
|
||||
Warning 1292 Truncated incorrect innodb_concurrency_tickets value: '0'
|
||||
show variables like "innodb_concurrency_tickets";
|
||||
Variable_name Value
|
||||
innodb_concurrency_tickets 1
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
set global innodb_commit_concurrency=0;
|
||||
ERROR HY000: Incorrect arguments to SET
|
||||
ERROR 42000: Variable 'innodb_commit_concurrency' can't be set to the value of '0'
|
||||
select @@innodb_commit_concurrency;
|
||||
@@innodb_commit_concurrency
|
||||
1
|
||||
@@ -16,7 +16,7 @@ select @@innodb_commit_concurrency;
|
||||
@@innodb_commit_concurrency
|
||||
1
|
||||
set global innodb_commit_concurrency=0;
|
||||
ERROR HY000: Incorrect arguments to SET
|
||||
ERROR 42000: Variable 'innodb_commit_concurrency' can't be set to the value of '0'
|
||||
select @@innodb_commit_concurrency;
|
||||
@@innodb_commit_concurrency
|
||||
1
|
||||
|
||||
@@ -3,12 +3,12 @@ select @@innodb_commit_concurrency;
|
||||
@@innodb_commit_concurrency
|
||||
0
|
||||
set global innodb_commit_concurrency=1;
|
||||
ERROR HY000: Incorrect arguments to SET
|
||||
ERROR 42000: Variable 'innodb_commit_concurrency' can't be set to the value of '1'
|
||||
select @@innodb_commit_concurrency;
|
||||
@@innodb_commit_concurrency
|
||||
0
|
||||
set global innodb_commit_concurrency=42;
|
||||
ERROR HY000: Incorrect arguments to SET
|
||||
ERROR 42000: Variable 'innodb_commit_concurrency' can't be set to the value of '42'
|
||||
select @@innodb_commit_concurrency;
|
||||
@@innodb_commit_concurrency
|
||||
0
|
||||
|
||||
@@ -266,7 +266,7 @@ fid AsText(EndPoint(g))
|
||||
107 POINT(40 10)
|
||||
SELECT fid, GLength(g) FROM gis_line ORDER by fid;
|
||||
fid GLength(g)
|
||||
105 24.142135623731
|
||||
105 24.14213562373095
|
||||
106 40
|
||||
107 30
|
||||
SELECT fid, NumPoints(g) FROM gis_line ORDER by fid;
|
||||
@@ -292,7 +292,7 @@ Note 1003 select astext(startpoint(`test`.`gis_line`.`g`)) AS `AsText(StartPoint
|
||||
SELECT fid, AsText(Centroid(g)) FROM gis_polygon ORDER by fid;
|
||||
fid AsText(Centroid(g))
|
||||
108 POINT(15 15)
|
||||
109 POINT(25.4166666666667 25.4166666666667)
|
||||
109 POINT(25.416666666666668 25.416666666666668)
|
||||
110 POINT(20 10)
|
||||
SELECT fid, Area(g) FROM gis_polygon ORDER by fid;
|
||||
fid Area(g)
|
||||
@@ -326,8 +326,8 @@ fid IsClosed(g)
|
||||
116 0
|
||||
SELECT fid, AsText(Centroid(g)) FROM gis_multi_polygon ORDER by fid;
|
||||
fid AsText(Centroid(g))
|
||||
117 POINT(55.5885277530424 17.426536064114)
|
||||
118 POINT(55.5885277530424 17.426536064114)
|
||||
117 POINT(55.58852775304245 17.426536064113982)
|
||||
118 POINT(55.58852775304245 17.426536064113982)
|
||||
119 POINT(2 2)
|
||||
SELECT fid, Area(g) FROM gis_multi_polygon ORDER by fid;
|
||||
fid Area(g)
|
||||
|
||||
@@ -175,12 +175,12 @@ Warning 1264 Out of range value for column 'f_float_3_1_u' at row 1
|
||||
select * from t1 where number =last_insert_id();
|
||||
number 4
|
||||
original_value 1e+1111111111a
|
||||
f_double 1.79769313486232e+308
|
||||
f_float 3.40282e+38
|
||||
f_double 1.7976931348623157e308
|
||||
f_float 3.40282e38
|
||||
f_double_7_2 99999.99
|
||||
f_float_4_3 9.999
|
||||
f_double_u 1.79769313486232e+308
|
||||
f_float_u 3.40282e+38
|
||||
f_double_u 1.7976931348623157e308
|
||||
f_float_u 3.40282e38
|
||||
f_double_15_1_u 99999999999999.9
|
||||
f_float_3_1_u 99.9
|
||||
set @value= "-1e+1111111111a";
|
||||
@@ -204,8 +204,8 @@ Warning 1264 Out of range value for column 'f_float_3_1_u' at row 1
|
||||
select * from t1 where number =last_insert_id();
|
||||
number 5
|
||||
original_value -1e+1111111111a
|
||||
f_double -1.79769313486232e+308
|
||||
f_float -3.40282e+38
|
||||
f_double -1.7976931348623157e308
|
||||
f_float -3.40282e38
|
||||
f_double_7_2 -99999.99
|
||||
f_float_4_3 -9.999
|
||||
f_double_u 0
|
||||
@@ -227,13 +227,13 @@ Warning 1264 Out of range value for column 'f_double_15_1_u' at row 1
|
||||
Warning 1264 Out of range value for column 'f_float_3_1_u' at row 1
|
||||
select * from t1 where number =last_insert_id();
|
||||
number 6
|
||||
original_value 1e+111
|
||||
f_double 1e+111
|
||||
f_float 3.40282e+38
|
||||
original_value 1e111
|
||||
f_double 1e111
|
||||
f_float 3.40282e38
|
||||
f_double_7_2 99999.99
|
||||
f_float_4_3 9.999
|
||||
f_double_u 1e+111
|
||||
f_float_u 3.40282e+38
|
||||
f_double_u 1e111
|
||||
f_float_u 3.40282e38
|
||||
f_double_15_1_u 99999999999999.9
|
||||
f_float_3_1_u 99.9
|
||||
set @value= -1e+111;
|
||||
@@ -248,9 +248,9 @@ Warning 1264 Out of range value for column 'f_double_15_1_u' at row 1
|
||||
Warning 1264 Out of range value for column 'f_float_3_1_u' at row 1
|
||||
select * from t1 where number =last_insert_id();
|
||||
number 7
|
||||
original_value -1e+111
|
||||
f_double -1e+111
|
||||
f_float -3.40282e+38
|
||||
original_value -1e111
|
||||
f_double -1e111
|
||||
f_float -3.40282e38
|
||||
f_double_7_2 -99999.99
|
||||
f_float_4_3 -9.999
|
||||
f_double_u 0
|
||||
@@ -524,42 +524,36 @@ INSERT INTO t1(a,b) VALUES (1.25e-175, 1.25e-175);
|
||||
INSERT INTO t1(a,c) VALUES (1.225e+0, 1.225e+0);
|
||||
INSERT INTO t1(a,c) VALUES (1.37e+0, 1.37e+0);
|
||||
INSERT INTO t1(a,c) VALUES (-1.37e+0, -1.37e+0);
|
||||
Warnings:
|
||||
Warning 1265 Data truncated for column 'c' at row 1
|
||||
INSERT INTO t1(a,c) VALUES (1.87e-3, 1.87e-3);
|
||||
Warnings:
|
||||
Warning 1265 Data truncated for column 'c' at row 1
|
||||
INSERT INTO t1(a,c) VALUES (-1.87e-2, -1.87e-2);
|
||||
Warnings:
|
||||
Warning 1265 Data truncated for column 'c' at row 1
|
||||
INSERT INTO t1(a,c) VALUES (5000e+0, 5000e+0);
|
||||
INSERT INTO t1(a,c) VALUES (-5000e+0, -5000e+0);
|
||||
Warnings:
|
||||
Warning 1265 Data truncated for column 'c' at row 1
|
||||
SELECT * FROM t1;
|
||||
a b c
|
||||
9.999999 10 10
|
||||
1.225e-05 1.2e-05 1e-0
|
||||
0.0001225 0.00012 NULL
|
||||
0.00001225 1.22e-5 1e-5
|
||||
0.0001225 1.22e-4 NULL
|
||||
0.1225 0.1225 NULL
|
||||
0.1225877 0.12259 NULL
|
||||
12.25 12.25 NULL
|
||||
12.25 12.25 12.2
|
||||
122500 122500 NULL
|
||||
12250000000 1.2e+10 NULL
|
||||
1.225e+15 1.2e+15 NULL
|
||||
12250000000 1.22e10 NULL
|
||||
1.225e15 1.22e15 NULL
|
||||
5000000 5000000 NULL
|
||||
1.25e+78 1.2e+78 NULL
|
||||
1.25e78 1.25e78 NULL
|
||||
1.25e-94 1.2e-94 NULL
|
||||
1.25e+203 1e+203 NULL
|
||||
1.25e203 1.2e203 NULL
|
||||
1.25e-175 1e-175 NULL
|
||||
1.225 NULL 1.23
|
||||
1.37 NULL 1.37
|
||||
-1.37 NULL -1.3
|
||||
0.00187 NULL 0.00
|
||||
-0.0187 NULL -0.0
|
||||
-1.37 NULL -1.4
|
||||
0.00187 NULL 2e-3
|
||||
-0.0187 NULL 0
|
||||
5000 NULL 5000
|
||||
-5000 NULL -500
|
||||
-5000 NULL -5e3
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (
|
||||
a char(20) NOT NULL,
|
||||
@@ -586,32 +580,30 @@ INSERT INTO t1(a,c) VALUES (1.37e+0, 1.37e+0);
|
||||
INSERT INTO t1(a,c) VALUES (-1.37e+0, -1.37e+0);
|
||||
INSERT INTO t1(a,c) VALUES (1.87e-3, 1.87e-3);
|
||||
INSERT INTO t1(a,c) VALUES (-1.87e-2, -1.87e-2);
|
||||
Warnings:
|
||||
Warning 1265 Data truncated for column 'c' at row 1
|
||||
INSERT INTO t1(a,c) VALUES (5000e+0, 5000e+0);
|
||||
INSERT INTO t1(a,c) VALUES (-5000e+0, -5000e+0);
|
||||
SELECT * FROM t1;
|
||||
a b c
|
||||
9.999999 10 9.999
|
||||
1.225e-05 1.2e-05 1e-05
|
||||
0.0001225 0.00012 NULL
|
||||
0.00001225 1.22e-5 1e-5
|
||||
0.0001225 1.22e-4 NULL
|
||||
0.1225 0.1225 NULL
|
||||
0.1225877 0.12259 NULL
|
||||
12.25 12.25 NULL
|
||||
12.25 12.25 12.25
|
||||
122500 122500 NULL
|
||||
12250000000 1.2e+10 NULL
|
||||
1.225e+15 1.2e+15 NULL
|
||||
12250000000 1.22e10 NULL
|
||||
1.225e15 1.22e15 NULL
|
||||
5000000 5000000 NULL
|
||||
1.25e+78 1.2e+78 NULL
|
||||
1.25e78 1.25e78 NULL
|
||||
1.25e-94 1.2e-94 NULL
|
||||
1.25e+203 1e+203 NULL
|
||||
1.25e203 1.2e203 NULL
|
||||
1.25e-175 1e-175 NULL
|
||||
1.225 NULL 1.225
|
||||
1.37 NULL 1.37
|
||||
-1.37 NULL -1.37
|
||||
0.00187 NULL 0.002
|
||||
-0.0187 NULL -0.01
|
||||
-0.0187 NULL -0.02
|
||||
5000 NULL 5000
|
||||
-5000 NULL -5000
|
||||
DROP TABLE t1;
|
||||
|
||||
@@ -274,8 +274,26 @@ Key_blocks_used 4
|
||||
show status like 'key_blocks_unused';
|
||||
Variable_name Value
|
||||
Key_blocks_unused KEY_BLOCKS_UNUSED
|
||||
create table t1 (a int primary key);
|
||||
cache index t1 in keycache2;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 assign_to_keycache status OK
|
||||
insert t1 values (1),(2),(3),(4),(5),(6),(7),(8);
|
||||
set global keycache2.key_buffer_size=0;
|
||||
select * from t1;
|
||||
a
|
||||
1
|
||||
2
|
||||
3
|
||||
4
|
||||
5
|
||||
6
|
||||
7
|
||||
8
|
||||
drop table t1;
|
||||
set global keycache3.key_buffer_size=100;
|
||||
Warnings:
|
||||
Warning 1292 Truncated incorrect key_buffer_size value: '100'
|
||||
set global keycache3.key_buffer_size=0;
|
||||
create table t1 (mytext text, FULLTEXT (mytext));
|
||||
insert t1 values ('aaabbb');
|
||||
@@ -334,8 +352,7 @@ test.t1 check status OK
|
||||
DROP TABLE t1,t2;
|
||||
set global key_cache_block_size= @my_key_cache_block_size;
|
||||
set @@global.key_buffer_size=0;
|
||||
Warnings:
|
||||
Warning 1438 Cannot drop default keycache
|
||||
ERROR HY000: Cannot drop default keycache
|
||||
select @@global.key_buffer_size;
|
||||
@@global.key_buffer_size
|
||||
2097152
|
||||
|
||||
@@ -251,15 +251,15 @@ CREATE TABLE t1 (c1 INT, c2 TIMESTAMP, c3 REAL, c4 DOUBLE);
|
||||
INSERT INTO t1 (c1, c2, c3, c4) VALUES (10, '1970-02-01 01:02:03', 1.1E-100, 1.1E+100);
|
||||
SELECT * FROM t1;
|
||||
c1 c2 c3 c4
|
||||
10 1970-02-01 01:02:03 1.1e-100 1.1e+100
|
||||
10 1970-02-01 01:02:03 1.1e-100 1.1e100
|
||||
SELECT * INTO OUTFILE 'MYSQLTEST_VARDIR/tmp/t1' FIELDS ENCLOSED BY '-' FROM t1;
|
||||
-10- -1970\-02\-01 01:02:03- -1.1e\-100- -1.1e+100-
|
||||
-10- -1970\-02\-01 01:02:03- -1.1e\-100- -1.1e100-
|
||||
EOF
|
||||
TRUNCATE t1;
|
||||
LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/t1' INTO TABLE t1 FIELDS ENCLOSED BY '-';
|
||||
SELECT * FROM t1;
|
||||
c1 c2 c3 c4
|
||||
10 1970-02-01 01:02:03 1.1e-100 1.1e+100
|
||||
10 1970-02-01 01:02:03 1.1e-100 1.1e100
|
||||
DROP TABLE t1;
|
||||
|
||||
# --
|
||||
|
||||
@@ -249,7 +249,7 @@ set @save_storage_engine= @@session.storage_engine;
|
||||
set storage_engine= MEMORY;
|
||||
alter table mysql.slow_log engine=NonExistentEngine;
|
||||
Warnings:
|
||||
Warning 1286 Unknown table engine 'NonExistentEngine'
|
||||
Warning 1286 Unknown storage engine 'NonExistentEngine'
|
||||
alter table mysql.slow_log engine=memory;
|
||||
ERROR HY000: This storage engine cannot be used for log tables"
|
||||
set storage_engine= @save_storage_engine;
|
||||
|
||||
@@ -604,7 +604,7 @@ a b
|
||||
4 4
|
||||
show master status /* there must be the UPDATE query event */;
|
||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||
master-bin.000001 207
|
||||
master-bin.000001 344
|
||||
delete from t1;
|
||||
delete from t2;
|
||||
insert into t1 values (1,2),(3,4),(4,4);
|
||||
@@ -614,7 +614,7 @@ UPDATE t2,t1 SET t2.a=t2.b where t2.a=t1.a;
|
||||
ERROR 23000: Duplicate entry '4' for key 'PRIMARY'
|
||||
show master status /* there must be the UPDATE query event */;
|
||||
File Position Binlog_Do_DB Binlog_Ignore_DB
|
||||
master-bin.000001 222
|
||||
master-bin.000001 359
|
||||
drop table t1, t2;
|
||||
set @@session.binlog_format= @sav_binlog_format;
|
||||
drop table if exists t1, t2, t3;
|
||||
|
||||
@@ -397,9 +397,9 @@ WARNING: --server-arg option not supported in this configuration.
|
||||
+---+
|
||||
| 1 |
|
||||
+---+
|
||||
Warning (Code 1286): Unknown table engine 'nonexistent'
|
||||
Warning (Code 1286): Unknown storage engine 'nonexistent'
|
||||
Warning (Code 1266): Using storage engine MyISAM for table 't2'
|
||||
Warning (Code 1286): Unknown table engine 'nonexistent2'
|
||||
Warning (Code 1286): Unknown storage engine 'nonexistent2'
|
||||
Warning (Code 1266): Using storage engine MyISAM for table 't2'
|
||||
Error (Code 1050): Table 't2' already exists
|
||||
drop tables t1, t2;
|
||||
|
||||
@@ -37,24 +37,60 @@ SET TIMESTAMP=1000000000/*!*/;
|
||||
create table t2 (id int auto_increment not null primary key)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
insert into t1 values ("abirvalg")
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET INSERT_ID=1/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
insert into t2 values ()
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
DELIMITER ;
|
||||
# End of log file
|
||||
ROLLBACK /* added by mysqlbinlog */;
|
||||
@@ -64,7 +100,6 @@ ROLLBACK /* added by mysqlbinlog */;
|
||||
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
|
||||
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
||||
DELIMITER /*!*/;
|
||||
use test/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
SET @@session.pseudo_thread_id=999999999/*!*/;
|
||||
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
|
||||
@@ -74,8 +109,24 @@ SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/
|
||||
SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
|
||||
SET @@session.lc_time_names=0/*!*/;
|
||||
SET @@session.collation_database=DEFAULT/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
use test/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
insert into t1 values ("Alas")
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
DELIMITER ;
|
||||
# End of log file
|
||||
ROLLBACK /* added by mysqlbinlog */;
|
||||
@@ -86,17 +137,6 @@ ROLLBACK /* added by mysqlbinlog */;
|
||||
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
||||
DELIMITER /*!*/;
|
||||
ROLLBACK/*!*/;
|
||||
SET INSERT_ID=1/*!*/;
|
||||
DELIMITER ;
|
||||
# End of log file
|
||||
ROLLBACK /* added by mysqlbinlog */;
|
||||
/*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/;
|
||||
|
||||
--- --position --
|
||||
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
|
||||
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
||||
DELIMITER /*!*/;
|
||||
use test/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
SET @@session.pseudo_thread_id=999999999/*!*/;
|
||||
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
|
||||
@@ -106,8 +146,69 @@ SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/
|
||||
SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
|
||||
SET @@session.lc_time_names=0/*!*/;
|
||||
SET @@session.collation_database=DEFAULT/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET INSERT_ID=1/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
DELIMITER ;
|
||||
# End of log file
|
||||
ROLLBACK /* added by mysqlbinlog */;
|
||||
/*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/;
|
||||
|
||||
--- --position --
|
||||
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
|
||||
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
||||
DELIMITER /*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
SET @@session.pseudo_thread_id=999999999/*!*/;
|
||||
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
|
||||
SET @@session.sql_mode=0/*!*/;
|
||||
SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
|
||||
/*!\C latin1 *//*!*/;
|
||||
SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
|
||||
SET @@session.lc_time_names=0/*!*/;
|
||||
SET @@session.collation_database=DEFAULT/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
use test/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
insert into t1 values ("Alas")
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
DELIMITER ;
|
||||
# End of log file
|
||||
ROLLBACK /* added by mysqlbinlog */;
|
||||
@@ -137,24 +238,60 @@ SET TIMESTAMP=1000000000/*!*/;
|
||||
create table t2 (id int auto_increment not null primary key)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
insert into t1 values ("abirvalg")
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET INSERT_ID=1/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
insert into t2 values ()
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
DELIMITER ;
|
||||
# End of log file
|
||||
ROLLBACK /* added by mysqlbinlog */;
|
||||
@@ -164,7 +301,6 @@ ROLLBACK /* added by mysqlbinlog */;
|
||||
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
|
||||
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
||||
DELIMITER /*!*/;
|
||||
use test/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
SET @@session.pseudo_thread_id=999999999/*!*/;
|
||||
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
|
||||
@@ -174,8 +310,24 @@ SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/
|
||||
SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
|
||||
SET @@session.lc_time_names=0/*!*/;
|
||||
SET @@session.collation_database=DEFAULT/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
use test/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (word)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
insert into t1 values ("Alas")
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
DELIMITER ;
|
||||
# End of log file
|
||||
ROLLBACK /* added by mysqlbinlog */;
|
||||
@@ -186,17 +338,6 @@ ROLLBACK /* added by mysqlbinlog */;
|
||||
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
||||
DELIMITER /*!*/;
|
||||
ROLLBACK/*!*/;
|
||||
SET INSERT_ID=1/*!*/;
|
||||
DELIMITER ;
|
||||
# End of log file
|
||||
ROLLBACK /* added by mysqlbinlog */;
|
||||
/*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/;
|
||||
|
||||
--- --position --
|
||||
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
|
||||
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
||||
DELIMITER /*!*/;
|
||||
use test/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
SET @@session.pseudo_thread_id=999999999/*!*/;
|
||||
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
|
||||
@@ -206,8 +347,69 @@ SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/
|
||||
SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
|
||||
SET @@session.lc_time_names=0/*!*/;
|
||||
SET @@session.collation_database=DEFAULT/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET INSERT_ID=1/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
DELIMITER ;
|
||||
# End of log file
|
||||
ROLLBACK /* added by mysqlbinlog */;
|
||||
/*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/;
|
||||
|
||||
--- --position --
|
||||
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
|
||||
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
|
||||
DELIMITER /*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
SET @@session.pseudo_thread_id=999999999/*!*/;
|
||||
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
|
||||
SET @@session.sql_mode=0/*!*/;
|
||||
SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
|
||||
/*!\C latin1 *//*!*/;
|
||||
SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
|
||||
SET @@session.lc_time_names=0/*!*/;
|
||||
SET @@session.collation_database=DEFAULT/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
use test/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
insert into t1 values ("Alas")
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
DELIMITER ;
|
||||
# End of log file
|
||||
ROLLBACK /* added by mysqlbinlog */;
|
||||
@@ -359,31 +561,73 @@ SET @@session.collation_database=DEFAULT/*!*/;
|
||||
create table t1 (a varchar(64) character set utf8)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (a)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
SET @@session.collation_database=7/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (a)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
SET @@session.collation_database=DEFAULT/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (a)
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (a)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (a)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
SET @@session.collation_database=7/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-a-0' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (a)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
SET @@session.collation_database=DEFAULT/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-b-0' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (a)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-c-0' INTO TABLE `t1` CHARACTER SET koi8r FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (a)
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
drop table t1
|
||||
/*!*/;
|
||||
DELIMITER ;
|
||||
@@ -399,9 +643,9 @@ We expect this value to be 1
|
||||
The bug being tested was that 'Query' lines were not preceded by '#'
|
||||
If the line is in the table, it had to have been preceded by a '#'
|
||||
|
||||
SELECT COUNT(*) AS `BUG#28293_expect_1` FROM patch WHERE a LIKE '%Query%';
|
||||
BUG#28293_expect_1
|
||||
1
|
||||
SELECT COUNT(*) AS `BUG#28293_expect_3` FROM patch WHERE a LIKE '%Query%';
|
||||
BUG#28293_expect_3
|
||||
3
|
||||
DROP TABLE patch;
|
||||
FLUSH LOGS;
|
||||
CREATE TABLE t1(a INT);
|
||||
@@ -426,7 +670,7 @@ CREATE TABLE t1 (a INT, b CHAR(64));
|
||||
flush logs;
|
||||
INSERT INTO t1 VALUES (1,USER());
|
||||
flush logs;
|
||||
mysqlbinlog var/log/master-bin.000017 > var/tmp/bug31611.sql
|
||||
mysqlbinlog var/log/master-bin.000018 > var/tmp/bug31611.sql
|
||||
mysql mysqltest1 -uuntrusted < var/tmp/bug31611.sql
|
||||
INSERT INTO t1 VALUES (1,USER());
|
||||
ERROR 42000: INSERT command denied to user 'untrusted'@'localhost' for table 't1'
|
||||
@@ -452,7 +696,7 @@ an_int 1000
|
||||
a_decimal 907.79
|
||||
a_string Just a test
|
||||
DROP TABLE t1;
|
||||
>> mysqlbinlog var/log/master-bin.000019 > var/tmp/bug32580.sql
|
||||
>> mysqlbinlog var/log/master-bin.000020 > var/tmp/bug32580.sql
|
||||
>> mysql test < var/tmp/bug32580.sql
|
||||
SELECT * FROM t1;
|
||||
a_real 158.883
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -495,10 +495,10 @@ c15 0000000000
|
||||
c16 -9223372036854775808
|
||||
c17 0
|
||||
c18 00000000000000000000
|
||||
c19 -3.40282e+38
|
||||
c19 -3.40282e38
|
||||
c20 1.17549e-38
|
||||
c21 000000000000
|
||||
c22 -1.7976931348623e+308
|
||||
c22 -1.7976931348623e308
|
||||
c23 2.2250738585072e-308
|
||||
c24 0000000000000000000000
|
||||
c25 -9999999999
|
||||
@@ -574,12 +574,12 @@ c15 4294967295
|
||||
c16 9223372036854775807
|
||||
c17 18446744073709551615
|
||||
c18 18446744073709551615
|
||||
c19 3.40282e+38
|
||||
c20 3.40282e+38
|
||||
c21 03.40282e+38
|
||||
c22 1.7976931348623e+308
|
||||
c23 1.7976931348623e+308
|
||||
c24 001.7976931348623e+308
|
||||
c19 3.40282e38
|
||||
c20 3.40282e38
|
||||
c21 003.40282e38
|
||||
c22 1.7976931348623e308
|
||||
c23 1.7976931348623e308
|
||||
c24 0001.7976931348623e308
|
||||
c25 9999999999
|
||||
c26 9999999999
|
||||
c27 9999999999
|
||||
@@ -1557,12 +1557,12 @@ c15 4294967295
|
||||
c16 9223372036854775807
|
||||
c17 18446744073709551615
|
||||
c18 18446744073709551615
|
||||
c19 3.40282e+38
|
||||
c20 3.40282e+38
|
||||
c21 03.40282e+38
|
||||
c22 1.7976931348623e+308
|
||||
c23 1.7976931348623e+308
|
||||
c24 001.7976931348623e+308
|
||||
c19 3.40282e38
|
||||
c20 3.40282e38
|
||||
c21 003.40282e38
|
||||
c22 1.7976931348623e308
|
||||
c23 1.7976931348623e308
|
||||
c24 0001.7976931348623e308
|
||||
c25 9999999999
|
||||
c26 9999999999
|
||||
c27 9999999999
|
||||
@@ -1636,10 +1636,10 @@ c15 0000000000
|
||||
c16 -9223372036854775808
|
||||
c17 0
|
||||
c18 00000000000000000000
|
||||
c19 -3.40282e+38
|
||||
c19 -3.40282e38
|
||||
c20 1.17549e-38
|
||||
c21 000000000000
|
||||
c22 -1.7976931348623e+308
|
||||
c22 -1.7976931348623e308
|
||||
c23 2.2250738585072e-308
|
||||
c24 0000000000000000000000
|
||||
c25 -9999999999
|
||||
@@ -2365,7 +2365,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
|
||||
### INSERT INTO test.t1
|
||||
### SET
|
||||
### @1=b'00000000' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'0000000000000000000000000000000000000000000000000000000000000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=-128 (128) /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=0 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -2458,7 +2458,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
|
||||
### INSERT INTO test.t1
|
||||
### SET
|
||||
### @1=b'00000001' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=127 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=-1 (255) /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -2553,7 +2553,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
|
||||
### INSERT INTO test.t1
|
||||
### SET
|
||||
### @1=NULL /* type=16 meta=256 nullable=1 is_null=1 */
|
||||
### @1=NULL /* type=16 meta=1 nullable=1 is_null=1 */
|
||||
### @2=NULL /* type=16 meta=2048 nullable=1 is_null=1 */
|
||||
### @3=NULL /* type=1 meta=0 nullable=1 is_null=1 */
|
||||
### @4=NULL /* type=1 meta=0 nullable=1 is_null=1 */
|
||||
@@ -2580,7 +2580,7 @@ BEGIN
|
||||
### @25=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @26=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @27=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=10 meta=0 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=14 meta=0 nullable=1 is_null=1 */
|
||||
### @29=NULL /* type=12 meta=0 nullable=1 is_null=1 */
|
||||
### @30=1000000000 /* TIMESTAMP meta=0 nullable=0 is_null=0 */
|
||||
### @31=NULL /* TIMESTAMP meta=0 nullable=1 is_null=1 */
|
||||
@@ -2634,7 +2634,7 @@ BEGIN
|
||||
### @79=3 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### INSERT INTO test.t1
|
||||
### SET
|
||||
### @1=b'00000001' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=127 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=0 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -2727,7 +2727,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
|
||||
### UPDATE test.t1
|
||||
### WHERE
|
||||
### @1=b'00000000' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'0000000000000000000000000000000000000000000000000000000000000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=-128 (128) /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=0 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -2807,7 +2807,7 @@ BEGIN
|
||||
### @78=b'00000000' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
|
||||
### @79=1 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=b'00000001' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=127 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=-1 (255) /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -2900,7 +2900,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
|
||||
### UPDATE test.t1
|
||||
### WHERE
|
||||
### @1=b'00000001' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=127 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=-1 (255) /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -2980,7 +2980,7 @@ BEGIN
|
||||
### @78=b'00000111' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
|
||||
### @79=2 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=b'00000000' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'0000000000000000000000000000000000000000000000000000000000000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=-128 (128) /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=0 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -3073,7 +3073,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
|
||||
### UPDATE test.t1
|
||||
### WHERE
|
||||
### @1=NULL /* type=16 meta=256 nullable=1 is_null=1 */
|
||||
### @1=NULL /* type=16 meta=1 nullable=1 is_null=1 */
|
||||
### @2=NULL /* type=16 meta=2048 nullable=1 is_null=1 */
|
||||
### @3=NULL /* type=1 meta=0 nullable=1 is_null=1 */
|
||||
### @4=NULL /* type=1 meta=0 nullable=1 is_null=1 */
|
||||
@@ -3100,7 +3100,7 @@ BEGIN
|
||||
### @25=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @26=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @27=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=10 meta=0 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=14 meta=0 nullable=1 is_null=1 */
|
||||
### @29=NULL /* type=12 meta=0 nullable=1 is_null=1 */
|
||||
### @30=1000000000 /* TIMESTAMP meta=0 nullable=0 is_null=0 */
|
||||
### @31=NULL /* TIMESTAMP meta=0 nullable=1 is_null=1 */
|
||||
@@ -3153,7 +3153,7 @@ BEGIN
|
||||
### @78=NULL /* TIMESTAMP meta=63489 nullable=1 is_null=1 */
|
||||
### @79=3 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=b'00000001' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=127 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=0 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -3246,7 +3246,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
|
||||
### UPDATE test.t1
|
||||
### WHERE
|
||||
### @1=b'00000001' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=127 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=0 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -3326,7 +3326,7 @@ BEGIN
|
||||
### @78=b'00000110' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
|
||||
### @79=4 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=NULL /* type=16 meta=256 nullable=1 is_null=1 */
|
||||
### @1=NULL /* type=16 meta=1 nullable=1 is_null=1 */
|
||||
### @2=NULL /* type=16 meta=2048 nullable=1 is_null=1 */
|
||||
### @3=NULL /* type=1 meta=0 nullable=1 is_null=1 */
|
||||
### @4=NULL /* type=1 meta=0 nullable=1 is_null=1 */
|
||||
@@ -3353,7 +3353,7 @@ BEGIN
|
||||
### @25=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @26=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @27=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=10 meta=0 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=14 meta=0 nullable=1 is_null=1 */
|
||||
### @29=NULL /* type=12 meta=0 nullable=1 is_null=1 */
|
||||
### @30=1000000000 /* TIMESTAMP meta=0 nullable=0 is_null=0 */
|
||||
### @31=NULL /* TIMESTAMP meta=0 nullable=1 is_null=1 */
|
||||
@@ -3419,7 +3419,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
|
||||
### DELETE FROM test.t1
|
||||
### WHERE
|
||||
### @1=b'00000001' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=127 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=-1 (255) /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -3512,7 +3512,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
|
||||
### DELETE FROM test.t1
|
||||
### WHERE
|
||||
### @1=b'00000000' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'0000000000000000000000000000000000000000000000000000000000000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=-128 (128) /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=0 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -3605,7 +3605,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
|
||||
### DELETE FROM test.t1
|
||||
### WHERE
|
||||
### @1=b'00000001' /* BIT(8) meta=256 nullable=1 is_null=0 */
|
||||
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
|
||||
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
|
||||
### @3=127 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
### @4=0 /* TINYINT meta=0 nullable=1 is_null=0 */
|
||||
@@ -3698,7 +3698,7 @@ BEGIN
|
||||
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
|
||||
### DELETE FROM test.t1
|
||||
### WHERE
|
||||
### @1=NULL /* type=16 meta=256 nullable=1 is_null=1 */
|
||||
### @1=NULL /* type=16 meta=1 nullable=1 is_null=1 */
|
||||
### @2=NULL /* type=16 meta=2048 nullable=1 is_null=1 */
|
||||
### @3=NULL /* type=1 meta=0 nullable=1 is_null=1 */
|
||||
### @4=NULL /* type=1 meta=0 nullable=1 is_null=1 */
|
||||
@@ -3725,7 +3725,7 @@ BEGIN
|
||||
### @25=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @26=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @27=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=10 meta=0 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=14 meta=0 nullable=1 is_null=1 */
|
||||
### @29=NULL /* type=12 meta=0 nullable=1 is_null=1 */
|
||||
### @30=1000000000 /* TIMESTAMP meta=0 nullable=0 is_null=0 */
|
||||
### @31=NULL /* TIMESTAMP meta=0 nullable=1 is_null=1 */
|
||||
|
||||
@@ -495,10 +495,10 @@ c15 0000000000
|
||||
c16 -9223372036854775808
|
||||
c17 0
|
||||
c18 00000000000000000000
|
||||
c19 -3.40282e+38
|
||||
c19 -3.40282e38
|
||||
c20 1.17549e-38
|
||||
c21 000000000000
|
||||
c22 -1.7976931348623e+308
|
||||
c22 -1.7976931348623e308
|
||||
c23 2.2250738585072e-308
|
||||
c24 0000000000000000000000
|
||||
c25 -9999999999
|
||||
@@ -574,12 +574,12 @@ c15 4294967295
|
||||
c16 9223372036854775807
|
||||
c17 18446744073709551615
|
||||
c18 18446744073709551615
|
||||
c19 3.40282e+38
|
||||
c20 3.40282e+38
|
||||
c21 03.40282e+38
|
||||
c22 1.7976931348623e+308
|
||||
c23 1.7976931348623e+308
|
||||
c24 001.7976931348623e+308
|
||||
c19 3.40282e38
|
||||
c20 3.40282e38
|
||||
c21 003.40282e38
|
||||
c22 1.7976931348623e308
|
||||
c23 1.7976931348623e308
|
||||
c24 0001.7976931348623e308
|
||||
c25 9999999999
|
||||
c26 9999999999
|
||||
c27 9999999999
|
||||
@@ -1557,12 +1557,12 @@ c15 4294967295
|
||||
c16 9223372036854775807
|
||||
c17 18446744073709551615
|
||||
c18 18446744073709551615
|
||||
c19 3.40282e+38
|
||||
c20 3.40282e+38
|
||||
c21 03.40282e+38
|
||||
c22 1.7976931348623e+308
|
||||
c23 1.7976931348623e+308
|
||||
c24 001.7976931348623e+308
|
||||
c19 3.40282e38
|
||||
c20 3.40282e38
|
||||
c21 003.40282e38
|
||||
c22 1.7976931348623e308
|
||||
c23 1.7976931348623e308
|
||||
c24 0001.7976931348623e308
|
||||
c25 9999999999
|
||||
c26 9999999999
|
||||
c27 9999999999
|
||||
@@ -1636,10 +1636,10 @@ c15 0000000000
|
||||
c16 -9223372036854775808
|
||||
c17 0
|
||||
c18 00000000000000000000
|
||||
c19 -3.40282e+38
|
||||
c19 -3.40282e38
|
||||
c20 1.17549e-38
|
||||
c21 000000000000
|
||||
c22 -1.7976931348623e+308
|
||||
c22 -1.7976931348623e308
|
||||
c23 2.2250738585072e-308
|
||||
c24 0000000000000000000000
|
||||
c25 -9999999999
|
||||
@@ -2584,7 +2584,7 @@ BEGIN
|
||||
### @25=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @26=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @27=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=10 meta=0 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=14 meta=0 nullable=1 is_null=1 */
|
||||
### @29=NULL /* type=12 meta=0 nullable=1 is_null=1 */
|
||||
### @30=1000000000 /* TIMESTAMP meta=0 nullable=0 is_null=0 */
|
||||
### @31=NULL /* TIMESTAMP meta=0 nullable=1 is_null=1 */
|
||||
@@ -3110,7 +3110,7 @@ BEGIN
|
||||
### @25=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @26=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @27=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=10 meta=0 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=14 meta=0 nullable=1 is_null=1 */
|
||||
### @29=NULL /* type=12 meta=0 nullable=1 is_null=1 */
|
||||
### @30=1000000000 /* TIMESTAMP meta=0 nullable=0 is_null=0 */
|
||||
### @31=NULL /* TIMESTAMP meta=0 nullable=1 is_null=1 */
|
||||
@@ -3365,7 +3365,7 @@ BEGIN
|
||||
### @25=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @26=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @27=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=10 meta=0 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=14 meta=0 nullable=1 is_null=1 */
|
||||
### @29=NULL /* type=12 meta=0 nullable=1 is_null=1 */
|
||||
### @30=1000000000 /* TIMESTAMP meta=0 nullable=0 is_null=0 */
|
||||
### @31=NULL /* TIMESTAMP meta=0 nullable=1 is_null=1 */
|
||||
@@ -3745,7 +3745,7 @@ BEGIN
|
||||
### @25=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @26=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @27=NULL /* type=246 meta=2560 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=10 meta=0 nullable=1 is_null=1 */
|
||||
### @28=NULL /* type=14 meta=0 nullable=1 is_null=1 */
|
||||
### @29=NULL /* type=12 meta=0 nullable=1 is_null=1 */
|
||||
### @30=1000000000 /* TIMESTAMP meta=0 nullable=0 is_null=0 */
|
||||
### @31=NULL /* TIMESTAMP meta=0 nullable=1 is_null=1 */
|
||||
|
||||
@@ -215,7 +215,7 @@ COMMIT/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
TRUNCATE TABLE t1
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
@@ -223,21 +223,84 @@ SET TIMESTAMP=1000000000/*!*/;
|
||||
TRUNCATE TABLE t1
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Xid = #
|
||||
COMMIT/*!*/;
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
|
||||
### INSERT INTO test.t2
|
||||
### SET
|
||||
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### INSERT INTO test.t2
|
||||
### SET
|
||||
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### INSERT INTO test.t2
|
||||
### SET
|
||||
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
|
||||
### UPDATE test.t2
|
||||
### WHERE
|
||||
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=11 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### UPDATE test.t2
|
||||
### WHERE
|
||||
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### UPDATE test.t2
|
||||
### WHERE
|
||||
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=13 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
TRUNCATE TABLE t1
|
||||
COMMIT
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Xid = #
|
||||
COMMIT/*!*/;
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
|
||||
### DELETE FROM test.t2
|
||||
### WHERE
|
||||
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
@@ -293,71 +356,14 @@ BEGIN
|
||||
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
|
||||
### INSERT INTO test.t2
|
||||
### SET
|
||||
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### INSERT INTO test.t2
|
||||
### SET
|
||||
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### INSERT INTO test.t2
|
||||
### SET
|
||||
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
|
||||
### UPDATE test.t2
|
||||
### WHERE
|
||||
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=11 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### UPDATE test.t2
|
||||
### WHERE
|
||||
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### UPDATE test.t2
|
||||
### WHERE
|
||||
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=13 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
|
||||
### DELETE FROM test.t2
|
||||
### WHERE
|
||||
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Xid = #
|
||||
COMMIT/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
TRUNCATE TABLE t1
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Xid = #
|
||||
COMMIT/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
TRUNCATE TABLE t2
|
||||
@@ -369,55 +375,6 @@ BEGIN
|
||||
/*!*/;
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
|
||||
### INSERT INTO test.t1
|
||||
### SET
|
||||
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### INSERT INTO test.t1
|
||||
### SET
|
||||
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### INSERT INTO test.t1
|
||||
### SET
|
||||
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
|
||||
### UPDATE test.t1
|
||||
### WHERE
|
||||
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=11 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### UPDATE test.t1
|
||||
### WHERE
|
||||
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### UPDATE test.t1
|
||||
### WHERE
|
||||
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
### SET
|
||||
### @1=13 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
|
||||
### DELETE FROM test.t1
|
||||
### WHERE
|
||||
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
|
||||
### INSERT INTO test.t2
|
||||
@@ -433,6 +390,16 @@ BEGIN
|
||||
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
|
||||
@@ -458,6 +425,16 @@ BEGIN
|
||||
### @1=13 /* INT meta=0 nullable=1 is_null=0 */
|
||||
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
COMMIT
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
/*!*/;
|
||||
# at #
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
|
||||
@@ -468,12 +445,7 @@ BEGIN
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
ROLLBACK
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
BEGIN
|
||||
COMMIT
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
@@ -481,9 +453,6 @@ SET TIMESTAMP=1000000000/*!*/;
|
||||
TRUNCATE TABLE t1
|
||||
/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Xid = #
|
||||
COMMIT/*!*/;
|
||||
# at #
|
||||
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
|
||||
SET TIMESTAMP=1000000000/*!*/;
|
||||
TRUNCATE TABLE t2
|
||||
|
||||
992
mysql-test/r/mysqld--help-notwin.result
Normal file
992
mysql-test/r/mysqld--help-notwin.result
Normal file
@@ -0,0 +1,992 @@
|
||||
The following options may be given as the first argument:
|
||||
--print-defaults Print the program argument list and exit
|
||||
--no-defaults Don't read default options from any options file
|
||||
--defaults-file=# Only read default options from the given file #
|
||||
--defaults-extra-file=# Read this file after the global files are read
|
||||
|
||||
--abort-slave-event-count=#
|
||||
Option used by mysql-test for debugging and testing of
|
||||
replication.
|
||||
--allow-suspicious-udfs
|
||||
Allows use of UDFs consisting of only one symbol xxx()
|
||||
without corresponding xxx_init() or xxx_deinit(). That
|
||||
also means that one can load any function from any
|
||||
library, for example exit() from libc.so
|
||||
-a, --ansi Use ANSI SQL syntax instead of MySQL syntax. This mode
|
||||
will also set transaction isolation level 'serializable'.
|
||||
--archive[=name] Enable or disable ARCHIVE plugin. Possible values are ON,
|
||||
OFF, FORCE (don't start if the plugin fails to load).
|
||||
--auto-increment-increment[=#]
|
||||
Auto-increment columns are incremented by this
|
||||
--auto-increment-offset[=#]
|
||||
Offset added to Auto-increment columns. Used when
|
||||
auto-increment-increment != 1
|
||||
--automatic-sp-privileges
|
||||
Creating and dropping stored procedures alters ACLs
|
||||
(Defaults to on; use --skip-automatic-sp-privileges to disable.)
|
||||
--back-log=# The number of outstanding connection requests MySQL can
|
||||
have. This comes into play when the main MySQL thread
|
||||
gets very many connection requests in a very short time
|
||||
-b, --basedir=name Path to installation directory. All paths are usually
|
||||
resolved relative to this
|
||||
--big-tables Allow big result sets by saving all temporary sets on
|
||||
file (Solves most 'table full' errors)
|
||||
--bind-address=name IP address to bind to.
|
||||
--binlog-cache-size=#
|
||||
The size of the cache to hold the SQL statements for the
|
||||
binary log during a transaction. If you often use big,
|
||||
multi-statement transactions you can increase this to get
|
||||
more performance
|
||||
--binlog-do-db=name Tells the master it should log updates for the specified
|
||||
database, and exclude all others not explicitly
|
||||
mentioned.
|
||||
--binlog-format=name
|
||||
What form of binary logging the master will use: either
|
||||
ROW for row-based binary logging, STATEMENT for
|
||||
statement-based binary logging, or MIXED. MIXED is
|
||||
statement-based binary logging except for those
|
||||
statements where only row-based is correct: those which
|
||||
involve user-defined functions (i.e. UDFs) or the UUID()
|
||||
function; for those, row-based binary logging is
|
||||
automatically used. If NDBCLUSTER is enabled and
|
||||
binlog-format is MIXED, the format switches to row-based
|
||||
and back implicitly per each query accessing an
|
||||
NDBCLUSTER table
|
||||
--binlog-ignore-db=name
|
||||
Tells the master that updates to the given database
|
||||
should not be logged tothe binary log.
|
||||
--binlog-row-event-max-size=#
|
||||
The maximum size of a row-based binary log event in
|
||||
bytes. Rows will be grouped into events smaller than this
|
||||
size if possible. The value has to be a multiple of 256.
|
||||
--blackhole[=name] Enable or disable BLACKHOLE plugin. Possible values are
|
||||
ON, OFF, FORCE (don't start if the plugin fails to load).
|
||||
--bootstrap Used by mysql installation scripts.
|
||||
--bulk-insert-buffer-size=#
|
||||
Size of tree cache used in bulk insert optimisation. Note
|
||||
that this is a limit per thread!
|
||||
--character-set-client-handshake
|
||||
Don't ignore client side character set value sent during
|
||||
handshake.
|
||||
(Defaults to on; use --skip-character-set-client-handshake to disable.)
|
||||
--character-set-filesystem=name
|
||||
Set the filesystem character set.
|
||||
-C, --character-set-server=name
|
||||
Set the default character set.
|
||||
--character-sets-dir=name
|
||||
Directory where character sets are
|
||||
-r, --chroot=name Chroot mysqld daemon during startup.
|
||||
--collation-server=name
|
||||
Set the default collation.
|
||||
--completion-type=name
|
||||
The transaction completion type, one of NO_CHAIN, CHAIN,
|
||||
RELEASE
|
||||
--concurrent-insert[=name]
|
||||
Use concurrent insert with MyISAM. Possible values are
|
||||
NEVER, AUTO, ALWAYS
|
||||
--connect-timeout=# The number of seconds the mysqld server is waiting for a
|
||||
connect packet before responding with 'Bad handshake'
|
||||
--console Write error output on screen; Don't remove the console
|
||||
window on windows.
|
||||
--core-file Write core on errors.
|
||||
-h, --datadir=name Path to the database root directory
|
||||
--date-format=name The DATE format (ignored)
|
||||
--datetime-format=name
|
||||
The DATETIME format (ignored)
|
||||
-C, --default-character-set=name
|
||||
Set the default character set (deprecated option, use
|
||||
--character-set-server instead).
|
||||
--default-collation=name
|
||||
Set the default collation (deprecated option, use
|
||||
--collation-server instead).
|
||||
--default-storage-engine=name
|
||||
The default storage engine for new tables
|
||||
--default-time-zone=name
|
||||
Set the default time zone.
|
||||
--default-week-format=#
|
||||
The default week format used by WEEK() functions
|
||||
--delay-key-write[=name]
|
||||
Type of DELAY_KEY_WRITE
|
||||
--delay-key-write-for-all-tables
|
||||
Don't flush key buffers between writes for any MyISAM
|
||||
table (Deprecated option, use --delay-key-write=all
|
||||
instead).
|
||||
--delayed-insert-limit=#
|
||||
After inserting delayed_insert_limit rows, the INSERT
|
||||
DELAYED handler will check if there are any SELECT
|
||||
statements pending. If so, it allows these to execute
|
||||
before continuing
|
||||
--delayed-insert-timeout=#
|
||||
How long a INSERT DELAYED thread should wait for INSERT
|
||||
statements before terminating
|
||||
--delayed-queue-size=#
|
||||
What size queue (in rows) should be allocated for
|
||||
handling INSERT DELAYED. If the queue becomes full, any
|
||||
client that does INSERT DELAYED will wait until there is
|
||||
room in the queue again
|
||||
--disconnect-slave-event-count=#
|
||||
Option used by mysql-test for debugging and testing of
|
||||
replication.
|
||||
--div-precision-increment=#
|
||||
Precision of the result of '/' operator will be increased
|
||||
on that value
|
||||
--enable-locking Deprecated option, use --external-locking instead.
|
||||
--engine-condition-pushdown
|
||||
Push supported query conditions to the storage engine.
|
||||
Deprecated, use --optimizer-switch instead.
|
||||
(Defaults to on; use --skip-engine-condition-pushdown to disable.)
|
||||
--event-scheduler[=name]
|
||||
Enable the event scheduler. Possible values are ON, OFF,
|
||||
and DISABLED (keep the event scheduler completely
|
||||
deactivated, it cannot be activated run-time)
|
||||
-T, --exit-info[=#] Used for debugging; Use at your own risk!
|
||||
--expire-logs-days=#
|
||||
If non-zero, binary logs will be purged after
|
||||
expire_logs_days days; possible purges happen at startup
|
||||
and at binary log rotation
|
||||
--external-locking Use system (external) locking (disabled by default).
|
||||
With this option enabled you can run myisamchk to test
|
||||
(not repair) tables while the MySQL server is running.
|
||||
Disable with --skip-external-locking.
|
||||
--federated[=name] Enable or disable FEDERATED plugin. Possible values are
|
||||
ON, OFF, FORCE (don't start if the plugin fails to load).
|
||||
--flush Flush MyISAM tables to disk between SQL commands
|
||||
--flush-time=# A dedicated thread is created to flush all tables at the
|
||||
given interval
|
||||
--ft-boolean-syntax=name
|
||||
List of operators for MATCH ... AGAINST ( ... IN BOOLEAN
|
||||
MODE)
|
||||
--ft-max-word-len=# The maximum length of the word to be included in a
|
||||
FULLTEXT index. Note: FULLTEXT indexes must be rebuilt
|
||||
after changing this variable
|
||||
--ft-min-word-len=# The minimum length of the word to be included in a
|
||||
FULLTEXT index. Note: FULLTEXT indexes must be rebuilt
|
||||
after changing this variable
|
||||
--ft-query-expansion-limit=#
|
||||
Number of best matches to use for query expansion
|
||||
--ft-stopword-file=name
|
||||
Use stopwords from this file instead of built-in list
|
||||
--gdb Set up signals usable for debugging
|
||||
--general-log Log connections and queries to a table or log file.
|
||||
Defaults logging to a file hostname.log or a table
|
||||
mysql.general_logif --log-output=TABLE is used
|
||||
--general-log-file=name
|
||||
Log connections and queries to given file
|
||||
--group-concat-max-len=#
|
||||
The maximum length of the result of function
|
||||
GROUP_CONCAT()
|
||||
-?, --help Display this help and exit.
|
||||
--ignore-builtin-innodb
|
||||
Disable initialization of builtin InnoDB plugin
|
||||
--init-connect=name Command(s) that are executed for each new connection
|
||||
--init-file=name Read SQL commands from this file at startup
|
||||
--init-rpl-role=name
|
||||
Set the replication role.
|
||||
--init-slave=name Command(s) that are executed by a slave server each time
|
||||
the SQL thread starts
|
||||
--interactive-timeout=#
|
||||
The number of seconds the server waits for activity on an
|
||||
interactive connection before closing it
|
||||
--join-buffer-size=#
|
||||
The size of the buffer that is used for full joins
|
||||
--keep-files-on-create
|
||||
Don't overwrite stale .MYD and .MYI even if no directory
|
||||
is specified
|
||||
--key-buffer-size=# The size of the buffer used for index blocks for MyISAM
|
||||
tables. Increase this to get better index handling (for
|
||||
all reads and multiple writes) to as much as you can
|
||||
afford
|
||||
--key-cache-age-threshold=#
|
||||
This characterizes the number of hits a hot block has to
|
||||
be untouched until it is considered aged enough to be
|
||||
downgraded to a warm block. This specifies the percentage
|
||||
ratio of that number of hits to the total number of
|
||||
blocks in key cache
|
||||
--key-cache-block-size=#
|
||||
The default size of key cache blocks
|
||||
--key-cache-division-limit=#
|
||||
The minimum percentage of warm blocks in key cache
|
||||
-L, --language=name Client error messages in given language. May be given as
|
||||
a full path. Deprecated. Use --lc-messages-dir instead.
|
||||
--large-pages Enable support for large pages
|
||||
--lc-messages=name Set the language used for the error messages.
|
||||
-L, --lc-messages-dir=name
|
||||
Directory where error messages are
|
||||
--lc-time-names=name
|
||||
Set the language used for the month names and the days of
|
||||
the week.
|
||||
--local-infile Enable LOAD DATA LOCAL INFILE
|
||||
(Defaults to on; use --skip-local-infile to disable.)
|
||||
-l, --log[=name] Log connections and queries to file (deprecated option,
|
||||
use --general-log/--general-log-file instead).
|
||||
--log-bin[=name] Log update queries in binary format. Optional (but
|
||||
strongly recommended to avoid replication problems if
|
||||
server's hostname changes) argument should be the chosen
|
||||
location for the binary log files.
|
||||
--log-bin-index=name
|
||||
File that holds the names for last binary log files.
|
||||
--log-bin-trust-function-creators
|
||||
If set to FALSE (the default), then when --log-bin is
|
||||
used, creation of a stored function (or trigger) is
|
||||
allowed only to users having the SUPER privilege and only
|
||||
if this stored function (trigger) may not break binary
|
||||
logging. Note that if ALL connections to this server
|
||||
ALWAYS use row-based binary logging, the security issues
|
||||
do not exist and the binary logging cannot break, so you
|
||||
can safely set this to TRUE
|
||||
--log-error[=name] Error log file
|
||||
--log-isam[=name] Log all MyISAM changes to file.
|
||||
-0, --log-long-format
|
||||
Log some extra information to update log. Please note
|
||||
that this option is deprecated; see --log-short-format
|
||||
option.
|
||||
--log-output=name Syntax: log-output=value[,value...], where "value" could
|
||||
be TABLE, FILE or NONE
|
||||
--log-queries-not-using-indexes
|
||||
Log queries that are executed without benefit of any
|
||||
index to the slow log if it is open
|
||||
--log-short-format Don't log extra information to update and slow-query
|
||||
logs.
|
||||
--log-slave-updates Tells the slave to log the updates from the slave thread
|
||||
to the binary log. You will need to turn it on if you
|
||||
plan to daisy-chain the slaves
|
||||
--log-slow-admin-statements
|
||||
Log slow OPTIMIZE, ANALYZE, ALTER and other
|
||||
administrative statements to the slow log if it is open.
|
||||
--log-slow-queries[=name]
|
||||
Log slow queries to a table or log file. Defaults logging
|
||||
to table mysql.slow_log or hostname-slow.log if
|
||||
--log-output=file is used. Must be enabled to activate
|
||||
other slow log options. Deprecated option, use
|
||||
--slow-query-log/--slow-query-log-file instead.
|
||||
--log-slow-slave-statements
|
||||
Log slow statements executed by slave thread to the slow
|
||||
log if it is open.
|
||||
--log-tc=name Path to transaction coordinator log (used for
|
||||
transactions that affect more than one storage engine,
|
||||
when binary log is disabled)
|
||||
--log-tc-size=# Size of transaction coordinator log.
|
||||
--log-update[=name] The update log is deprecated since version 5.0, is
|
||||
replaced by the binary log and this option justs turns on
|
||||
--log-bin instead.
|
||||
-W, --log-warnings[=#]
|
||||
Log some not critical warnings to the log file
|
||||
--long-query-time=# Log all queries that have taken more than long_query_time
|
||||
seconds to execute to file. The argument will be treated
|
||||
as a decimal value with microsecond precision
|
||||
--low-priority-updates
|
||||
INSERT/DELETE/UPDATE has lower priority than selects
|
||||
--lower-case-table-names[=#]
|
||||
If set to 1 table names are stored in lowercase on disk
|
||||
and table names will be case-insensitive. Should be set
|
||||
to 2 if you are using a case insensitive file system
|
||||
--master-info-file=name
|
||||
The location and name of the file that remembers the
|
||||
master and where the I/O replication thread is in the
|
||||
master's binlogs.
|
||||
--master-retry-count=#
|
||||
The number of tries the slave will make to connect to the
|
||||
master before giving up.
|
||||
--max-allowed-packet=#
|
||||
Max packet length to send to or receive from the server
|
||||
--max-binlog-cache-size=#
|
||||
Can be used to restrict the total size used to cache a
|
||||
multi-transaction query
|
||||
--max-binlog-dump-events=#
|
||||
Option used by mysql-test for debugging and testing of
|
||||
replication.
|
||||
--max-binlog-size=# Binary log will be rotated automatically when the size
|
||||
exceeds this value. Will also apply to relay logs if
|
||||
max_relay_log_size is 0
|
||||
--max-connect-errors=#
|
||||
If there is more than this number of interrupted
|
||||
connections from a host this host will be blocked from
|
||||
further connections
|
||||
--max-connections=# The number of simultaneous clients allowed
|
||||
--max-delayed-threads=#
|
||||
Don't start more than this number of threads to handle
|
||||
INSERT DELAYED statements. If set to zero INSERT DELAYED
|
||||
will be not used
|
||||
--max-error-count=# Max number of errors/warnings to store for a statement
|
||||
--max-heap-table-size=#
|
||||
Don't allow creation of heap tables bigger than this
|
||||
--max-join-size=# Joins that are probably going to read more than
|
||||
max_join_size records return an error
|
||||
--max-length-for-sort-data=#
|
||||
Max number of bytes in sorted records
|
||||
--max-prepared-stmt-count=#
|
||||
Maximum number of prepared statements in the server
|
||||
--max-relay-log-size=#
|
||||
If non-zero: relay log will be rotated automatically when
|
||||
the size exceeds this value; if zero: when the size
|
||||
exceeds max_binlog_size
|
||||
--max-seeks-for-key=#
|
||||
Limit assumed max number of seeks when looking up rows
|
||||
based on a key
|
||||
--max-sort-length=# The number of bytes to use when sorting BLOB or TEXT
|
||||
values (only the first max_sort_length bytes of each
|
||||
value are used; the rest are ignored)
|
||||
--max-sp-recursion-depth[=#]
|
||||
Maximum stored procedure recursion depth
|
||||
--max-tmp-tables=# Maximum number of temporary tables a client can keep open
|
||||
at a time
|
||||
--max-user-connections=#
|
||||
The maximum number of active connections for a single
|
||||
user (0 = no limit)
|
||||
--max-write-lock-count=#
|
||||
After this many write locks, allow some read locks to run
|
||||
in between
|
||||
--memlock Lock mysqld in memory.
|
||||
--min-examined-row-limit=#
|
||||
Don't write queries to slow log that examine fewer rows
|
||||
than that
|
||||
--multi-range-count=#
|
||||
Number of key ranges to request at once
|
||||
--myisam-block-size=#
|
||||
Block size to be used for MyISAM index pages
|
||||
--myisam-data-pointer-size=#
|
||||
Default pointer size to be used for MyISAM tables
|
||||
--myisam-max-sort-file-size=#
|
||||
Don't use the fast sort index method to created index if
|
||||
the temporary file would get bigger than this
|
||||
--myisam-mmap-size=#
|
||||
Restricts the total memory used for memory mapping of
|
||||
MySQL tables
|
||||
--myisam-recover-options[=name]
|
||||
Syntax: myisam-recover-options[=option[,option...]],
|
||||
where option can be DEFAULT, BACKUP, FORCE, QUICK, or OFF
|
||||
--myisam-repair-threads=#
|
||||
If larger than 1, when repairing a MyISAM table all
|
||||
indexes will be created in parallel, with one thread per
|
||||
index. The value of 1 disables parallel repair
|
||||
--myisam-sort-buffer-size=#
|
||||
The buffer that is allocated when sorting the index when
|
||||
doing a REPAIR or when creating indexes with CREATE INDEX
|
||||
or ALTER TABLE
|
||||
--myisam-stats-method=name
|
||||
Specifies how MyISAM index statistics collection code
|
||||
should treat NULLs. Possible values of name are
|
||||
NULLS_UNEQUAL (default behavior for 4.1 and later),
|
||||
NULLS_EQUAL (emulate 4.0 behavior), and NULLS_IGNORED
|
||||
--myisam-use-mmap Use memory mapping for reading and writing MyISAM tables
|
||||
--net-buffer-length=#
|
||||
Buffer length for TCP/IP and socket communication
|
||||
--net-read-timeout=#
|
||||
Number of seconds to wait for more data from a connection
|
||||
before aborting the read
|
||||
--net-retry-count=# If a read on a communication port is interrupted, retry
|
||||
this many times before giving up
|
||||
--net-write-timeout=#
|
||||
Number of seconds to wait for a block to be written to a
|
||||
connection before aborting the write
|
||||
-n, --new Use very new possible "unsafe" functions
|
||||
--old Use compatible behavior
|
||||
--old-alter-table Use old, non-optimized alter table
|
||||
--old-passwords Use old password encryption method (needed for 4.0 and
|
||||
older clients)
|
||||
--old-style-user-limits
|
||||
Enable old-style user limits (before 5.0.3 user resources
|
||||
were counted per each user+host vs. per account)
|
||||
--one-thread (deprecated): Only use one thread (for debugging under
|
||||
Linux). Use thread-handling=no-threads instead
|
||||
--open-files-limit=#
|
||||
If this is not 0, then mysqld will use this value to
|
||||
reserve file descriptors to use with setrlimit(). If this
|
||||
value is 0 then mysqld will reserve max_connections*5 or
|
||||
max_connections + table_cache*2 (whichever is larger)
|
||||
number of file descriptors
|
||||
--optimizer-prune-level=#
|
||||
Controls the heuristic(s) applied during query
|
||||
optimization to prune less-promising partial plans from
|
||||
the optimizer search space. Meaning: 0 - do not apply any
|
||||
heuristic, thus perform exhaustive search; 1 - prune
|
||||
plans based on number of retrieved rows
|
||||
--optimizer-search-depth=#
|
||||
Maximum depth of search performed by the query optimizer.
|
||||
Values larger than the number of relations in a query
|
||||
result in better query plans, but take longer to compile
|
||||
a query. Values smaller than the number of tables in a
|
||||
relation result in faster optimization, but may produce
|
||||
very bad query plans. If set to 0, the system will
|
||||
automatically pick a reasonable value; if set to 63, the
|
||||
optimizer will switch to the original find_best
|
||||
search(used for testing/comparison)
|
||||
--optimizer-switch=name
|
||||
optimizer_switch=option=val[,option=val...], where option
|
||||
is one of {index_merge, index_merge_union,
|
||||
index_merge_sort_union, index_merge_intersection,
|
||||
engine_condition_pushdown} and val is one of {on, off,
|
||||
default}
|
||||
--partition[=name] Enable or disable partition plugin. Possible values are
|
||||
ON, OFF, FORCE (don't start if the plugin fails to load).
|
||||
--performance-schema
|
||||
Enable the performance schema.
|
||||
--performance-schema-events-waits-history-long-size=#
|
||||
Number of rows in EVENTS_WAITS_HISTORY_LONG.
|
||||
--performance-schema-events-waits-history-size=#
|
||||
Number of rows per thread in EVENTS_WAITS_HISTORY.
|
||||
--performance-schema-max-cond-classes=#
|
||||
Maximum number of condition instruments.
|
||||
--performance-schema-max-cond-instances=#
|
||||
Maximum number of instrumented condition objects.
|
||||
--performance-schema-max-file-classes=#
|
||||
Maximum number of file instruments.
|
||||
--performance-schema-max-file-handles=#
|
||||
Maximum number of opened instrumented files.
|
||||
--performance-schema-max-file-instances=#
|
||||
Maximum number of instrumented files.
|
||||
--performance-schema-max-mutex-classes=#
|
||||
Maximum number of mutex instruments.
|
||||
--performance-schema-max-mutex-instances=#
|
||||
Maximum number of instrumented MUTEX objects.
|
||||
--performance-schema-max-rwlock-classes=#
|
||||
Maximum number of rwlock instruments.
|
||||
--performance-schema-max-rwlock-instances=#
|
||||
Maximum number of instrumented RWLOCK objects.
|
||||
--performance-schema-max-table-handles=#
|
||||
Maximum number of opened instrumented tables.
|
||||
--performance-schema-max-table-instances=#
|
||||
Maximum number of instrumented tables.
|
||||
--performance-schema-max-thread-classes=#
|
||||
Maximum number of thread instruments.
|
||||
--performance-schema-max-thread-instances=#
|
||||
Maximum number of instrumented threads.
|
||||
--pid-file=name Pid file used by safe_mysqld
|
||||
--plugin-dir=name Directory for plugins
|
||||
--plugin-load=name Optional semicolon-separated list of plugins to load,
|
||||
where each plugin is identified as name=library, where
|
||||
name is the plugin name and library is the plugin library
|
||||
in plugin_dir.
|
||||
-P, --port=# Port number to use for connection or 0 to default to,
|
||||
my.cnf, $MYSQL_TCP_PORT, /etc/services, built-in default
|
||||
(3306), whatever comes first
|
||||
--port-open-timeout=#
|
||||
Maximum time in seconds to wait for the port to become
|
||||
free. (Default: no wait)
|
||||
--preload-buffer-size=#
|
||||
The size of the buffer that is allocated when preloading
|
||||
indexes
|
||||
--profiling-history-size=#
|
||||
Limit of query profiling memory
|
||||
--query-alloc-block-size=#
|
||||
Allocation block size for query parsing and execution
|
||||
--query-cache-limit=#
|
||||
Don't cache results that are bigger than this
|
||||
--query-cache-min-res-unit=#
|
||||
The minimum size for blocks allocated by the query cache
|
||||
--query-cache-size=#
|
||||
The memory allocated to store results from old queries
|
||||
--query-cache-type=name
|
||||
OFF = Don't cache or retrieve results. ON = Cache all
|
||||
results except SELECT SQL_NO_CACHE ... queries. DEMAND =
|
||||
Cache only SELECT SQL_CACHE ... queries
|
||||
--query-cache-wlock-invalidate
|
||||
Invalidate queries in query cache on LOCK for write
|
||||
--query-prealloc-size=#
|
||||
Persistent buffer for query parsing and execution
|
||||
--range-alloc-block-size=#
|
||||
Allocation block size for storing ranges during
|
||||
optimization
|
||||
--read-buffer-size=#
|
||||
Each thread that does a sequential scan allocates a
|
||||
buffer of this size for each table it scans. If you do
|
||||
many sequential scans, you may want to increase this
|
||||
value
|
||||
--read-only Make all non-temporary tables read-only, with the
|
||||
exception for replication (slave) threads and users with
|
||||
the SUPER privilege
|
||||
--read-rnd-buffer-size=#
|
||||
When reading rows in sorted order after a sort, the rows
|
||||
are read through this buffer to avoid a disk seeks. If
|
||||
not set, then it's set to the value of record_buffer
|
||||
--record-buffer=# Deprecated; use --read-buffer-size instead.
|
||||
--relay-log=name The location and name to use for relay logs
|
||||
--relay-log-index=name
|
||||
The location and name to use for the file that keeps a
|
||||
list of the last relay logs
|
||||
--relay-log-info-file=name
|
||||
The location and name of the file that remembers where
|
||||
the SQL replication thread is in the relay logs
|
||||
--relay-log-purge if disabled - do not purge relay logs. if enabled - purge
|
||||
them as soon as they are no more needed
|
||||
(Defaults to on; use --skip-relay-log-purge to disable.)
|
||||
--relay-log-recovery
|
||||
Enables automatic relay log recovery right after the
|
||||
database startup, which means that the IO Thread starts
|
||||
re-fetching from the master right after the last
|
||||
transaction processed
|
||||
--relay-log-space-limit=#
|
||||
Maximum space to use for all relay logs
|
||||
--replicate-do-db=name
|
||||
Tells the slave thread to restrict replication to the
|
||||
specified database. To specify more than one database,
|
||||
use the directive multiple times, once for each database.
|
||||
Note that this will only work if you do not use
|
||||
cross-database queries such as UPDATE some_db.some_table
|
||||
SET foo='bar' while having selected a different or no
|
||||
database. If you need cross database updates to work,
|
||||
make sure you have 3.23.28 or later, and use
|
||||
replicate-wild-do-table=db_name.%.
|
||||
--replicate-do-table=name
|
||||
Tells the slave thread to restrict replication to the
|
||||
specified table. To specify more than one table, use the
|
||||
directive multiple times, once for each table. This will
|
||||
work for cross-database updates, in contrast to
|
||||
replicate-do-db.
|
||||
--replicate-ignore-db=name
|
||||
Tells the slave thread to not replicate to the specified
|
||||
database. To specify more than one database to ignore,
|
||||
use the directive multiple times, once for each database.
|
||||
This option will not work if you use cross database
|
||||
updates. If you need cross database updates to work, make
|
||||
sure you have 3.23.28 or later, and use
|
||||
replicate-wild-ignore-table=db_name.%.
|
||||
--replicate-ignore-table=name
|
||||
Tells the slave thread to not replicate to the specified
|
||||
table. To specify more than one table to ignore, use the
|
||||
directive multiple times, once for each table. This will
|
||||
work for cross-datbase updates, in contrast to
|
||||
replicate-ignore-db.
|
||||
--replicate-rewrite-db=name
|
||||
Updates to a database with a different name than the
|
||||
original. Example:
|
||||
replicate-rewrite-db=master_db_name->slave_db_name.
|
||||
--replicate-same-server-id
|
||||
In replication, if set to 1, do not skip events having
|
||||
our server id. Default value is 0 (to break infinite
|
||||
loops in circular replication). Can't be set to 1 if
|
||||
--log-slave-updates is used.
|
||||
--replicate-wild-do-table=name
|
||||
Tells the slave thread to restrict replication to the
|
||||
tables that match the specified wildcard pattern. To
|
||||
specify more than one table, use the directive multiple
|
||||
times, once for each table. This will work for
|
||||
cross-database updates. Example:
|
||||
replicate-wild-do-table=foo%.bar% will replicate only
|
||||
updates to tables in all databases that start with foo
|
||||
and whose table names start with bar.
|
||||
--replicate-wild-ignore-table=name
|
||||
Tells the slave thread to not replicate to the tables
|
||||
that match the given wildcard pattern. To specify more
|
||||
than one table to ignore, use the directive multiple
|
||||
times, once for each table. This will work for
|
||||
cross-database updates. Example:
|
||||
replicate-wild-ignore-table=foo%.bar% will not do updates
|
||||
to tables in databases that start with foo and whose
|
||||
table names start with bar.
|
||||
--report-host=name Hostname or IP of the slave to be reported to the master
|
||||
during slave registration. Will appear in the output of
|
||||
SHOW SLAVE HOSTS. Leave unset if you do not want the
|
||||
slave to register itself with the master. Note that it is
|
||||
not sufficient for the master to simply read the IP of
|
||||
the slave off the socket once the slave connects. Due to
|
||||
NAT and other routing issues, that IP may not be valid
|
||||
for connecting to the slave from the master or other
|
||||
hosts
|
||||
--report-password=name
|
||||
The account password of the slave to be reported to the
|
||||
master during slave registration
|
||||
--report-port=# Port for connecting to slave reported to the master
|
||||
during slave registration. Set it only if the slave is
|
||||
listening on a non-default port or if you have a special
|
||||
tunnel from the master or other clients to the slave. If
|
||||
not sure, leave this option unset
|
||||
--report-user=name The account user name of the slave to be reported to the
|
||||
master during slave registration
|
||||
--rpl-recovery-rank=#
|
||||
Unused, will be removed
|
||||
--safe-mode Skip some optimize stages (for testing).
|
||||
--safe-show-database
|
||||
Deprecated option; use GRANT SHOW DATABASES instead...
|
||||
--safe-user-create Don't allow new user creation by the user who has no
|
||||
write privileges to the mysql.user table.
|
||||
--secure-auth Disallow authentication for accounts that have old
|
||||
(pre-4.1) passwords
|
||||
--secure-file-priv=name
|
||||
Limit LOAD DATA, SELECT ... OUTFILE, and LOAD_FILE() to
|
||||
files within specified directory
|
||||
--server-id=# Uniquely identifies the server instance in the community
|
||||
of replication partners
|
||||
-O, --set-variable=name
|
||||
Change the value of a variable. Please note that this
|
||||
option is deprecated;you can set variables directly with
|
||||
--variable-name=value.
|
||||
--show-slave-auth-info
|
||||
Show user and password in SHOW SLAVE HOSTS on this master
|
||||
--skip-grant-tables Start without grant tables. This gives all users FULL
|
||||
ACCESS to all tables!
|
||||
--skip-host-cache Don't cache host names.
|
||||
--skip-locking Deprecated option, use --skip-external-locking instead.
|
||||
--skip-name-resolve Don't resolve hostnames. All hostnames are IP's or
|
||||
'localhost'.
|
||||
--skip-networking Don't allow connection with TCP/IP
|
||||
--skip-new Don't use new, possible wrong routines.
|
||||
--skip-show-database
|
||||
Don't allow 'SHOW DATABASE' commands
|
||||
--skip-slave-start If set, slave is not autostarted.
|
||||
--skip-stack-trace Don't print a stack trace on failure.
|
||||
--skip-symlink Don't allow symlinking of tables. Deprecated option. Use
|
||||
--skip-symbolic-links instead.
|
||||
--skip-thread-priority
|
||||
Don't give threads different priorities. This option is
|
||||
deprecated because it has no effect; the implied behavior
|
||||
is already the default.
|
||||
--slave-compressed-protocol
|
||||
Use compression on master/slave protocol
|
||||
--slave-exec-mode=name
|
||||
Modes for how replication events should be executed.
|
||||
Legal values are STRICT (default) and IDEMPOTENT. In
|
||||
IDEMPOTENT mode, replication will not stop for operations
|
||||
that are idempotent. In STRICT mode, replication will
|
||||
stop on any unexpected difference between the master and
|
||||
the slave
|
||||
--slave-load-tmpdir=name
|
||||
The location where the slave should put its temporary
|
||||
files when replicating a LOAD DATA INFILE command
|
||||
--slave-net-timeout=#
|
||||
Number of seconds to wait for more data from a
|
||||
master/slave connection before aborting the read
|
||||
--slave-skip-errors=name
|
||||
Tells the slave thread to continue replication when a
|
||||
query event returns an error from the provided list
|
||||
--slave-transaction-retries=#
|
||||
Number of times the slave SQL thread will retry a
|
||||
transaction in case it failed with a deadlock or elapsed
|
||||
lock wait timeout, before giving up and stopping
|
||||
--slave-type-conversions=name
|
||||
Set of slave type conversions that are enabled. Legal
|
||||
values are: ALL_LOSSY to enable lossy conversions and
|
||||
ALL_NON_LOSSY to enable non-lossy conversions. If the
|
||||
variable is assigned the empty set, no conversions are
|
||||
allowed and it is expected that the types match exactly.
|
||||
--slow-launch-time=#
|
||||
If creating the thread takes longer than this value (in
|
||||
seconds), the Slow_launch_threads counter will be
|
||||
incremented
|
||||
--slow-query-log Log slow queries to a table or log file. Defaults logging
|
||||
to a file hostname-slow.log or a table mysql.slow_log if
|
||||
--log-output=TABLE is used. Must be enabled to activate
|
||||
other slow log options
|
||||
--slow-query-log-file=name
|
||||
Log slow queries to given log file. Defaults logging to
|
||||
hostname-slow.log. Must be enabled to activate other slow
|
||||
log options
|
||||
--socket=name Socket file to use for connection
|
||||
--sort-buffer-size=#
|
||||
Each thread that needs to do a sort allocates a buffer of
|
||||
this size
|
||||
--sporadic-binlog-dump-fail
|
||||
Option used by mysql-test for debugging and testing of
|
||||
replication.
|
||||
--sql-bin-update-same
|
||||
The update log is deprecated since version 5.0, is
|
||||
replaced by the binary log and this option does nothing
|
||||
anymore.
|
||||
--sql-mode=name Syntax: sql-mode=mode[,mode[,mode...]]. See the manual
|
||||
for the complete list of valid sql modes
|
||||
-s, --symbolic-links
|
||||
Enable symbolic link support.
|
||||
--sync-binlog=# Synchronously flush binary log to disk after every #th
|
||||
event. Use 0 (default) to disable synchronous flushing
|
||||
--sync-frm Sync .frm files to disk on creation
|
||||
(Defaults to on; use --skip-sync-frm to disable.)
|
||||
--sync-master-info=#
|
||||
Synchronously flush master info to disk after every #th
|
||||
event. Use 0 (default) to disable synchronous flushing
|
||||
--sync-relay-log=# Synchronously flush relay log to disk after every #th
|
||||
event. Use 0 (default) to disable synchronous flushing
|
||||
--sync-relay-log-info=#
|
||||
Synchronously flush relay log info to disk after every
|
||||
#th transaction. Use 0 (default) to disable synchronous
|
||||
flushing
|
||||
--sysdate-is-now Non-default option to alias SYSDATE() to NOW() to make it
|
||||
safe-replicable. Since 5.0, SYSDATE() returns a `dynamic'
|
||||
value different for different invocations, even within
|
||||
the same statement.
|
||||
--table-cache=# Deprecated; use --table-open-cache instead.
|
||||
--table-definition-cache=#
|
||||
The number of cached table definitions
|
||||
--table-lock-wait-timeout=#
|
||||
Timeout in seconds to wait for a table level lock before
|
||||
returning an error. Used only if the connection has
|
||||
active cursors
|
||||
--table-open-cache=#
|
||||
The number of cached open tables
|
||||
--tc-heuristic-recover=name
|
||||
Decision to use in heuristic recover process. Possible
|
||||
values are COMMIT or ROLLBACK.
|
||||
--thread-cache-size=#
|
||||
How many threads we should keep in a cache for reuse
|
||||
--thread-handling=name
|
||||
Define threads usage for handling queries, one of
|
||||
one-thread-per-connection, no-threads
|
||||
--thread-stack=# The stack size for each thread
|
||||
--time-format=name The TIME format (ignored)
|
||||
--timed-mutexes Specify whether to time mutexes (only InnoDB mutexes are
|
||||
currently supported)
|
||||
--tmp-table-size=# If an internal in-memory temporary table exceeds this
|
||||
size, MySQL will automatically convert it to an on-disk
|
||||
MyISAM table
|
||||
-t, --tmpdir=name Path for temporary files. Several paths may be specified,
|
||||
separated by a colon (:), in this case they are used in a
|
||||
round-robin fashion
|
||||
--transaction-alloc-block-size=#
|
||||
Allocation block size for transactions to be stored in
|
||||
binary log
|
||||
--transaction-isolation=name
|
||||
Default transaction isolation level.
|
||||
--transaction-prealloc-size=#
|
||||
Persistent buffer for transactions to be stored in binary
|
||||
log
|
||||
--updatable-views-with-limit=name
|
||||
YES = Don't issue an error message (warning only) if a
|
||||
VIEW without presence of a key of the underlying table is
|
||||
used in queries with a LIMIT clause for updating. NO =
|
||||
Prohibit update of a VIEW, which does not contain a key
|
||||
of the underlying table and the query uses a LIMIT clause
|
||||
(usually get from GUI tools)
|
||||
-s, --use-symbolic-links
|
||||
Enable symbolic link support. Deprecated option; use
|
||||
--symbolic-links instead.
|
||||
-u, --user=name Run mysqld daemon as user.
|
||||
-v, --verbose Used with --help option for detailed help
|
||||
-V, --version Output version information and exit.
|
||||
--wait-timeout=# The number of seconds the server waits for activity on a
|
||||
connection before closing it
|
||||
-W, --warnings[=#] Deprecated; use --log-warnings instead.
|
||||
|
||||
Variables (--variable-name=value)
|
||||
and boolean options {FALSE|TRUE} Value (after reading options)
|
||||
------------------------------------------------- ------------------------
|
||||
abort-slave-event-count 0
|
||||
allow-suspicious-udfs FALSE
|
||||
archive ON
|
||||
auto-increment-increment 1
|
||||
auto-increment-offset 1
|
||||
automatic-sp-privileges TRUE
|
||||
back-log 50
|
||||
big-tables FALSE
|
||||
bind-address (No default value)
|
||||
binlog-cache-size 32768
|
||||
binlog-format STATEMENT
|
||||
binlog-row-event-max-size 1024
|
||||
blackhole ON
|
||||
bulk-insert-buffer-size 8388608
|
||||
character-set-client-handshake TRUE
|
||||
character-set-filesystem binary
|
||||
character-set-server latin1
|
||||
character-sets-dir MYSQL_SHAREDIR/charsets/
|
||||
chroot (No default value)
|
||||
collation-server latin1_swedish_ci
|
||||
completion-type NO_CHAIN
|
||||
concurrent-insert AUTO
|
||||
connect-timeout 10
|
||||
console FALSE
|
||||
date-format %Y-%m-%d
|
||||
datetime-format %Y-%m-%d %H:%i:%s
|
||||
default-character-set latin1
|
||||
default-collation latin1_swedish_ci
|
||||
default-storage-engine MyISAM
|
||||
default-time-zone (No default value)
|
||||
default-week-format 0
|
||||
delay-key-write ON
|
||||
delayed-insert-limit 100
|
||||
delayed-insert-timeout 300
|
||||
delayed-queue-size 1000
|
||||
disconnect-slave-event-count 0
|
||||
div-precision-increment 4
|
||||
enable-locking FALSE
|
||||
engine-condition-pushdown TRUE
|
||||
event-scheduler OFF
|
||||
expire-logs-days 0
|
||||
external-locking FALSE
|
||||
federated ON
|
||||
flush FALSE
|
||||
flush-time 0
|
||||
ft-boolean-syntax + -><()~*:""&|
|
||||
ft-max-word-len 84
|
||||
ft-min-word-len 4
|
||||
ft-query-expansion-limit 20
|
||||
ft-stopword-file (No default value)
|
||||
gdb FALSE
|
||||
general-log FALSE
|
||||
group-concat-max-len 1024
|
||||
help TRUE
|
||||
ignore-builtin-innodb FALSE
|
||||
init-connect
|
||||
init-file (No default value)
|
||||
init-rpl-role MASTER
|
||||
init-slave
|
||||
interactive-timeout 28800
|
||||
join-buffer-size 131072
|
||||
keep-files-on-create FALSE
|
||||
key-buffer-size 8388608
|
||||
key-cache-age-threshold 300
|
||||
key-cache-block-size 1024
|
||||
key-cache-division-limit 100
|
||||
language MYSQL_SHAREDIR/
|
||||
large-pages FALSE
|
||||
lc-messages en_US
|
||||
lc-messages-dir MYSQL_SHAREDIR/
|
||||
lc-time-names en_US
|
||||
local-infile TRUE
|
||||
log-bin (No default value)
|
||||
log-bin-index (No default value)
|
||||
log-bin-trust-function-creators FALSE
|
||||
log-error
|
||||
log-isam myisam.log
|
||||
log-output FILE
|
||||
log-queries-not-using-indexes FALSE
|
||||
log-short-format FALSE
|
||||
log-slave-updates FALSE
|
||||
log-slow-admin-statements FALSE
|
||||
log-slow-slave-statements FALSE
|
||||
log-tc tc.log
|
||||
log-tc-size 24576
|
||||
log-update (No default value)
|
||||
log-warnings 1
|
||||
long-query-time 10
|
||||
low-priority-updates FALSE
|
||||
lower-case-table-names 1
|
||||
master-info-file master.info
|
||||
master-retry-count 86400
|
||||
max-allowed-packet 1048576
|
||||
max-binlog-cache-size 18446744073709547520
|
||||
max-binlog-dump-events 0
|
||||
max-binlog-size 1073741824
|
||||
max-connect-errors 10
|
||||
max-connections 151
|
||||
max-delayed-threads 20
|
||||
max-error-count 64
|
||||
max-heap-table-size 16777216
|
||||
max-join-size 18446744073709551615
|
||||
max-length-for-sort-data 1024
|
||||
max-prepared-stmt-count 16382
|
||||
max-relay-log-size 0
|
||||
max-seeks-for-key 18446744073709551615
|
||||
max-sort-length 1024
|
||||
max-sp-recursion-depth 0
|
||||
max-tmp-tables 32
|
||||
max-user-connections 0
|
||||
max-write-lock-count 18446744073709551615
|
||||
memlock FALSE
|
||||
min-examined-row-limit 0
|
||||
multi-range-count 256
|
||||
myisam-block-size 1024
|
||||
myisam-data-pointer-size 6
|
||||
myisam-max-sort-file-size 9223372036853727232
|
||||
myisam-mmap-size 18446744073709551615
|
||||
myisam-recover-options OFF
|
||||
myisam-repair-threads 1
|
||||
myisam-sort-buffer-size 8388608
|
||||
myisam-stats-method nulls_unequal
|
||||
myisam-use-mmap FALSE
|
||||
net-buffer-length 16384
|
||||
net-read-timeout 30
|
||||
net-retry-count 10
|
||||
net-write-timeout 60
|
||||
new FALSE
|
||||
old FALSE
|
||||
old-alter-table FALSE
|
||||
old-passwords FALSE
|
||||
old-style-user-limits FALSE
|
||||
optimizer-prune-level 1
|
||||
optimizer-search-depth 62
|
||||
optimizer-switch index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
partition ON
|
||||
performance-schema FALSE
|
||||
performance-schema-events-waits-history-long-size 10000
|
||||
performance-schema-events-waits-history-size 10
|
||||
performance-schema-max-cond-classes 80
|
||||
performance-schema-max-cond-instances 1000
|
||||
performance-schema-max-file-classes 50
|
||||
performance-schema-max-file-handles 32768
|
||||
performance-schema-max-file-instances 10000
|
||||
performance-schema-max-mutex-classes 200
|
||||
performance-schema-max-mutex-instances 1000
|
||||
performance-schema-max-rwlock-classes 20
|
||||
performance-schema-max-rwlock-instances 1000
|
||||
performance-schema-max-table-handles 100000
|
||||
performance-schema-max-table-instances 50000
|
||||
performance-schema-max-thread-classes 50
|
||||
performance-schema-max-thread-instances 1000
|
||||
plugin-dir MYSQL_LIBDIR/mysql/plugin
|
||||
plugin-load (No default value)
|
||||
port 3306
|
||||
port-open-timeout 0
|
||||
preload-buffer-size 32768
|
||||
profiling-history-size 15
|
||||
query-alloc-block-size 8192
|
||||
query-cache-limit 1048576
|
||||
query-cache-min-res-unit 4096
|
||||
query-cache-size 0
|
||||
query-cache-type ON
|
||||
query-cache-wlock-invalidate FALSE
|
||||
query-prealloc-size 8192
|
||||
range-alloc-block-size 4096
|
||||
read-buffer-size 131072
|
||||
read-only FALSE
|
||||
read-rnd-buffer-size 262144
|
||||
record-buffer 131072
|
||||
relay-log (No default value)
|
||||
relay-log-index (No default value)
|
||||
relay-log-info-file relay-log.info
|
||||
relay-log-purge TRUE
|
||||
relay-log-recovery FALSE
|
||||
relay-log-space-limit 0
|
||||
replicate-same-server-id FALSE
|
||||
report-host (No default value)
|
||||
report-password (No default value)
|
||||
report-port 3306
|
||||
report-user (No default value)
|
||||
rpl-recovery-rank 0
|
||||
safe-user-create FALSE
|
||||
secure-auth FALSE
|
||||
secure-file-priv (No default value)
|
||||
server-id 0
|
||||
show-slave-auth-info FALSE
|
||||
skip-grant-tables TRUE
|
||||
skip-networking FALSE
|
||||
skip-show-database FALSE
|
||||
skip-slave-start FALSE
|
||||
slave-compressed-protocol FALSE
|
||||
slave-exec-mode STRICT
|
||||
slave-net-timeout 3600
|
||||
slave-skip-errors (No default value)
|
||||
slave-transaction-retries 10
|
||||
slave-type-conversions
|
||||
slow-launch-time 2
|
||||
slow-query-log FALSE
|
||||
socket /tmp/mysql.sock
|
||||
sort-buffer-size 2097152
|
||||
sporadic-binlog-dump-fail FALSE
|
||||
sql-mode
|
||||
symbolic-links FALSE
|
||||
sync-binlog 0
|
||||
sync-frm TRUE
|
||||
sync-master-info 0
|
||||
sync-relay-log 0
|
||||
sync-relay-log-info 0
|
||||
sysdate-is-now FALSE
|
||||
table-cache 400
|
||||
table-definition-cache 400
|
||||
table-lock-wait-timeout 50
|
||||
table-open-cache 400
|
||||
tc-heuristic-recover COMMIT
|
||||
thread-cache-size 0
|
||||
thread-handling one-thread-per-connection
|
||||
thread-stack 262144
|
||||
time-format %H:%i:%s
|
||||
timed-mutexes FALSE
|
||||
tmp-table-size 16777216
|
||||
transaction-alloc-block-size 8192
|
||||
transaction-isolation REPEATABLE-READ
|
||||
transaction-prealloc-size 4096
|
||||
updatable-views-with-limit YES
|
||||
use-symbolic-links FALSE
|
||||
verbose TRUE
|
||||
wait-timeout 28800
|
||||
warnings 1
|
||||
|
||||
To see what values a running MySQL server is using, type
|
||||
'mysqladmin variables' instead of 'mysqld --verbose --help'.
|
||||
998
mysql-test/r/mysqld--help-win.result
Normal file
998
mysql-test/r/mysqld--help-win.result
Normal file
@@ -0,0 +1,998 @@
|
||||
The following options may be given as the first argument:
|
||||
--print-defaults Print the program argument list and exit
|
||||
--no-defaults Don't read default options from any options file
|
||||
--defaults-file=# Only read default options from the given file #
|
||||
--defaults-extra-file=# Read this file after the global files are read
|
||||
|
||||
--abort-slave-event-count=#
|
||||
Option used by mysql-test for debugging and testing of
|
||||
replication.
|
||||
--allow-suspicious-udfs
|
||||
Allows use of UDFs consisting of only one symbol xxx()
|
||||
without corresponding xxx_init() or xxx_deinit(). That
|
||||
also means that one can load any function from any
|
||||
library, for example exit() from libc.so
|
||||
-a, --ansi Use ANSI SQL syntax instead of MySQL syntax. This mode
|
||||
will also set transaction isolation level 'serializable'.
|
||||
--archive[=name] Enable or disable ARCHIVE plugin. Possible values are ON,
|
||||
OFF, FORCE (don't start if the plugin fails to load).
|
||||
--auto-increment-increment[=#]
|
||||
Auto-increment columns are incremented by this
|
||||
--auto-increment-offset[=#]
|
||||
Offset added to Auto-increment columns. Used when
|
||||
auto-increment-increment != 1
|
||||
--automatic-sp-privileges
|
||||
Creating and dropping stored procedures alters ACLs
|
||||
(Defaults to on; use --skip-automatic-sp-privileges to disable.)
|
||||
--back-log=# The number of outstanding connection requests MySQL can
|
||||
have. This comes into play when the main MySQL thread
|
||||
gets very many connection requests in a very short time
|
||||
-b, --basedir=name Path to installation directory. All paths are usually
|
||||
resolved relative to this
|
||||
--big-tables Allow big result sets by saving all temporary sets on
|
||||
file (Solves most 'table full' errors)
|
||||
--bind-address=name IP address to bind to.
|
||||
--binlog-cache-size=#
|
||||
The size of the cache to hold the SQL statements for the
|
||||
binary log during a transaction. If you often use big,
|
||||
multi-statement transactions you can increase this to get
|
||||
more performance
|
||||
--binlog-do-db=name Tells the master it should log updates for the specified
|
||||
database, and exclude all others not explicitly
|
||||
mentioned.
|
||||
--binlog-format=name
|
||||
What form of binary logging the master will use: either
|
||||
ROW for row-based binary logging, STATEMENT for
|
||||
statement-based binary logging, or MIXED. MIXED is
|
||||
statement-based binary logging except for those
|
||||
statements where only row-based is correct: those which
|
||||
involve user-defined functions (i.e. UDFs) or the UUID()
|
||||
function; for those, row-based binary logging is
|
||||
automatically used. If NDBCLUSTER is enabled and
|
||||
binlog-format is MIXED, the format switches to row-based
|
||||
and back implicitly per each query accessing an
|
||||
NDBCLUSTER table
|
||||
--binlog-ignore-db=name
|
||||
Tells the master that updates to the given database
|
||||
should not be logged tothe binary log.
|
||||
--binlog-row-event-max-size=#
|
||||
The maximum size of a row-based binary log event in
|
||||
bytes. Rows will be grouped into events smaller than this
|
||||
size if possible. The value has to be a multiple of 256.
|
||||
--blackhole[=name] Enable or disable BLACKHOLE plugin. Possible values are
|
||||
ON, OFF, FORCE (don't start if the plugin fails to load).
|
||||
--bootstrap Used by mysql installation scripts.
|
||||
--bulk-insert-buffer-size=#
|
||||
Size of tree cache used in bulk insert optimisation. Note
|
||||
that this is a limit per thread!
|
||||
--character-set-client-handshake
|
||||
Don't ignore client side character set value sent during
|
||||
handshake.
|
||||
(Defaults to on; use --skip-character-set-client-handshake to disable.)
|
||||
--character-set-filesystem=name
|
||||
Set the filesystem character set.
|
||||
-C, --character-set-server=name
|
||||
Set the default character set.
|
||||
--character-sets-dir=name
|
||||
Directory where character sets are
|
||||
-r, --chroot=name Chroot mysqld daemon during startup.
|
||||
--collation-server=name
|
||||
Set the default collation.
|
||||
--completion-type=name
|
||||
The transaction completion type, one of NO_CHAIN, CHAIN,
|
||||
RELEASE
|
||||
--concurrent-insert[=name]
|
||||
Use concurrent insert with MyISAM. Possible values are
|
||||
NEVER, AUTO, ALWAYS
|
||||
--connect-timeout=# The number of seconds the mysqld server is waiting for a
|
||||
connect packet before responding with 'Bad handshake'
|
||||
--console Write error output on screen; Don't remove the console
|
||||
window on windows.
|
||||
--core-file Write core on errors.
|
||||
-h, --datadir=name Path to the database root directory
|
||||
--date-format=name The DATE format (ignored)
|
||||
--datetime-format=name
|
||||
The DATETIME format (ignored)
|
||||
-C, --default-character-set=name
|
||||
Set the default character set (deprecated option, use
|
||||
--character-set-server instead).
|
||||
--default-collation=name
|
||||
Set the default collation (deprecated option, use
|
||||
--collation-server instead).
|
||||
--default-storage-engine=name
|
||||
The default storage engine for new tables
|
||||
--default-time-zone=name
|
||||
Set the default time zone.
|
||||
--default-week-format=#
|
||||
The default week format used by WEEK() functions
|
||||
--delay-key-write[=name]
|
||||
Type of DELAY_KEY_WRITE
|
||||
--delay-key-write-for-all-tables
|
||||
Don't flush key buffers between writes for any MyISAM
|
||||
table (Deprecated option, use --delay-key-write=all
|
||||
instead).
|
||||
--delayed-insert-limit=#
|
||||
After inserting delayed_insert_limit rows, the INSERT
|
||||
DELAYED handler will check if there are any SELECT
|
||||
statements pending. If so, it allows these to execute
|
||||
before continuing
|
||||
--delayed-insert-timeout=#
|
||||
How long a INSERT DELAYED thread should wait for INSERT
|
||||
statements before terminating
|
||||
--delayed-queue-size=#
|
||||
What size queue (in rows) should be allocated for
|
||||
handling INSERT DELAYED. If the queue becomes full, any
|
||||
client that does INSERT DELAYED will wait until there is
|
||||
room in the queue again
|
||||
--disconnect-slave-event-count=#
|
||||
Option used by mysql-test for debugging and testing of
|
||||
replication.
|
||||
--div-precision-increment=#
|
||||
Precision of the result of '/' operator will be increased
|
||||
on that value
|
||||
--enable-locking Deprecated option, use --external-locking instead.
|
||||
--engine-condition-pushdown
|
||||
Push supported query conditions to the storage engine.
|
||||
Deprecated, use --optimizer-switch instead.
|
||||
(Defaults to on; use --skip-engine-condition-pushdown to disable.)
|
||||
--event-scheduler[=name]
|
||||
Enable the event scheduler. Possible values are ON, OFF,
|
||||
and DISABLED (keep the event scheduler completely
|
||||
deactivated, it cannot be activated run-time)
|
||||
-T, --exit-info[=#] Used for debugging; Use at your own risk!
|
||||
--expire-logs-days=#
|
||||
If non-zero, binary logs will be purged after
|
||||
expire_logs_days days; possible purges happen at startup
|
||||
and at binary log rotation
|
||||
--external-locking Use system (external) locking (disabled by default).
|
||||
With this option enabled you can run myisamchk to test
|
||||
(not repair) tables while the MySQL server is running.
|
||||
Disable with --skip-external-locking.
|
||||
--federated[=name] Enable or disable FEDERATED plugin. Possible values are
|
||||
ON, OFF, FORCE (don't start if the plugin fails to load).
|
||||
--flush Flush MyISAM tables to disk between SQL commands
|
||||
--flush-time=# A dedicated thread is created to flush all tables at the
|
||||
given interval
|
||||
--ft-boolean-syntax=name
|
||||
List of operators for MATCH ... AGAINST ( ... IN BOOLEAN
|
||||
MODE)
|
||||
--ft-max-word-len=# The maximum length of the word to be included in a
|
||||
FULLTEXT index. Note: FULLTEXT indexes must be rebuilt
|
||||
after changing this variable
|
||||
--ft-min-word-len=# The minimum length of the word to be included in a
|
||||
FULLTEXT index. Note: FULLTEXT indexes must be rebuilt
|
||||
after changing this variable
|
||||
--ft-query-expansion-limit=#
|
||||
Number of best matches to use for query expansion
|
||||
--ft-stopword-file=name
|
||||
Use stopwords from this file instead of built-in list
|
||||
--gdb Set up signals usable for debugging
|
||||
--general-log Log connections and queries to a table or log file.
|
||||
Defaults logging to a file hostname.log or a table
|
||||
mysql.general_logif --log-output=TABLE is used
|
||||
--general-log-file=name
|
||||
Log connections and queries to given file
|
||||
--group-concat-max-len=#
|
||||
The maximum length of the result of function
|
||||
GROUP_CONCAT()
|
||||
-?, --help Display this help and exit.
|
||||
--ignore-builtin-innodb
|
||||
Disable initialization of builtin InnoDB plugin
|
||||
--init-connect=name Command(s) that are executed for each new connection
|
||||
--init-file=name Read SQL commands from this file at startup
|
||||
--init-rpl-role=name
|
||||
Set the replication role.
|
||||
--init-slave=name Command(s) that are executed by a slave server each time
|
||||
the SQL thread starts
|
||||
--interactive-timeout=#
|
||||
The number of seconds the server waits for activity on an
|
||||
interactive connection before closing it
|
||||
--join-buffer-size=#
|
||||
The size of the buffer that is used for full joins
|
||||
--keep-files-on-create
|
||||
Don't overwrite stale .MYD and .MYI even if no directory
|
||||
is specified
|
||||
--key-buffer-size=# The size of the buffer used for index blocks for MyISAM
|
||||
tables. Increase this to get better index handling (for
|
||||
all reads and multiple writes) to as much as you can
|
||||
afford
|
||||
--key-cache-age-threshold=#
|
||||
This characterizes the number of hits a hot block has to
|
||||
be untouched until it is considered aged enough to be
|
||||
downgraded to a warm block. This specifies the percentage
|
||||
ratio of that number of hits to the total number of
|
||||
blocks in key cache
|
||||
--key-cache-block-size=#
|
||||
The default size of key cache blocks
|
||||
--key-cache-division-limit=#
|
||||
The minimum percentage of warm blocks in key cache
|
||||
-L, --language=name Client error messages in given language. May be given as
|
||||
a full path. Deprecated. Use --lc-messages-dir instead.
|
||||
--lc-messages=name Set the language used for the error messages.
|
||||
-L, --lc-messages-dir=name
|
||||
Directory where error messages are
|
||||
--lc-time-names=name
|
||||
Set the language used for the month names and the days of
|
||||
the week.
|
||||
--local-infile Enable LOAD DATA LOCAL INFILE
|
||||
(Defaults to on; use --skip-local-infile to disable.)
|
||||
-l, --log[=name] Log connections and queries to file (deprecated option,
|
||||
use --general-log/--general-log-file instead).
|
||||
--log-bin[=name] Log update queries in binary format. Optional (but
|
||||
strongly recommended to avoid replication problems if
|
||||
server's hostname changes) argument should be the chosen
|
||||
location for the binary log files.
|
||||
--log-bin-index=name
|
||||
File that holds the names for last binary log files.
|
||||
--log-bin-trust-function-creators
|
||||
If set to FALSE (the default), then when --log-bin is
|
||||
used, creation of a stored function (or trigger) is
|
||||
allowed only to users having the SUPER privilege and only
|
||||
if this stored function (trigger) may not break binary
|
||||
logging. Note that if ALL connections to this server
|
||||
ALWAYS use row-based binary logging, the security issues
|
||||
do not exist and the binary logging cannot break, so you
|
||||
can safely set this to TRUE
|
||||
--log-error[=name] Error log file
|
||||
--log-isam[=name] Log all MyISAM changes to file.
|
||||
-0, --log-long-format
|
||||
Log some extra information to update log. Please note
|
||||
that this option is deprecated; see --log-short-format
|
||||
option.
|
||||
--log-output=name Syntax: log-output=value[,value...], where "value" could
|
||||
be TABLE, FILE or NONE
|
||||
--log-queries-not-using-indexes
|
||||
Log queries that are executed without benefit of any
|
||||
index to the slow log if it is open
|
||||
--log-short-format Don't log extra information to update and slow-query
|
||||
logs.
|
||||
--log-slave-updates Tells the slave to log the updates from the slave thread
|
||||
to the binary log. You will need to turn it on if you
|
||||
plan to daisy-chain the slaves
|
||||
--log-slow-admin-statements
|
||||
Log slow OPTIMIZE, ANALYZE, ALTER and other
|
||||
administrative statements to the slow log if it is open.
|
||||
--log-slow-queries[=name]
|
||||
Log slow queries to a table or log file. Defaults logging
|
||||
to table mysql.slow_log or hostname-slow.log if
|
||||
--log-output=file is used. Must be enabled to activate
|
||||
other slow log options. Deprecated option, use
|
||||
--slow-query-log/--slow-query-log-file instead.
|
||||
--log-slow-slave-statements
|
||||
Log slow statements executed by slave thread to the slow
|
||||
log if it is open.
|
||||
--log-tc=name Path to transaction coordinator log (used for
|
||||
transactions that affect more than one storage engine,
|
||||
when binary log is disabled)
|
||||
--log-tc-size=# Size of transaction coordinator log.
|
||||
--log-update[=name] The update log is deprecated since version 5.0, is
|
||||
replaced by the binary log and this option justs turns on
|
||||
--log-bin instead.
|
||||
-W, --log-warnings[=#]
|
||||
Log some not critical warnings to the log file
|
||||
--long-query-time=# Log all queries that have taken more than long_query_time
|
||||
seconds to execute to file. The argument will be treated
|
||||
as a decimal value with microsecond precision
|
||||
--low-priority-updates
|
||||
INSERT/DELETE/UPDATE has lower priority than selects
|
||||
--lower-case-table-names[=#]
|
||||
If set to 1 table names are stored in lowercase on disk
|
||||
and table names will be case-insensitive. Should be set
|
||||
to 2 if you are using a case insensitive file system
|
||||
--master-info-file=name
|
||||
The location and name of the file that remembers the
|
||||
master and where the I/O replication thread is in the
|
||||
master's binlogs.
|
||||
--master-retry-count=#
|
||||
The number of tries the slave will make to connect to the
|
||||
master before giving up.
|
||||
--max-allowed-packet=#
|
||||
Max packet length to send to or receive from the server
|
||||
--max-binlog-cache-size=#
|
||||
Can be used to restrict the total size used to cache a
|
||||
multi-transaction query
|
||||
--max-binlog-dump-events=#
|
||||
Option used by mysql-test for debugging and testing of
|
||||
replication.
|
||||
--max-binlog-size=# Binary log will be rotated automatically when the size
|
||||
exceeds this value. Will also apply to relay logs if
|
||||
max_relay_log_size is 0
|
||||
--max-connect-errors=#
|
||||
If there is more than this number of interrupted
|
||||
connections from a host this host will be blocked from
|
||||
further connections
|
||||
--max-connections=# The number of simultaneous clients allowed
|
||||
--max-delayed-threads=#
|
||||
Don't start more than this number of threads to handle
|
||||
INSERT DELAYED statements. If set to zero INSERT DELAYED
|
||||
will be not used
|
||||
--max-error-count=# Max number of errors/warnings to store for a statement
|
||||
--max-heap-table-size=#
|
||||
Don't allow creation of heap tables bigger than this
|
||||
--max-join-size=# Joins that are probably going to read more than
|
||||
max_join_size records return an error
|
||||
--max-length-for-sort-data=#
|
||||
Max number of bytes in sorted records
|
||||
--max-prepared-stmt-count=#
|
||||
Maximum number of prepared statements in the server
|
||||
--max-relay-log-size=#
|
||||
If non-zero: relay log will be rotated automatically when
|
||||
the size exceeds this value; if zero: when the size
|
||||
exceeds max_binlog_size
|
||||
--max-seeks-for-key=#
|
||||
Limit assumed max number of seeks when looking up rows
|
||||
based on a key
|
||||
--max-sort-length=# The number of bytes to use when sorting BLOB or TEXT
|
||||
values (only the first max_sort_length bytes of each
|
||||
value are used; the rest are ignored)
|
||||
--max-sp-recursion-depth[=#]
|
||||
Maximum stored procedure recursion depth
|
||||
--max-tmp-tables=# Maximum number of temporary tables a client can keep open
|
||||
at a time
|
||||
--max-user-connections=#
|
||||
The maximum number of active connections for a single
|
||||
user (0 = no limit)
|
||||
--max-write-lock-count=#
|
||||
After this many write locks, allow some read locks to run
|
||||
in between
|
||||
--memlock Lock mysqld in memory.
|
||||
--min-examined-row-limit=#
|
||||
Don't write queries to slow log that examine fewer rows
|
||||
than that
|
||||
--multi-range-count=#
|
||||
Number of key ranges to request at once
|
||||
--myisam-block-size=#
|
||||
Block size to be used for MyISAM index pages
|
||||
--myisam-data-pointer-size=#
|
||||
Default pointer size to be used for MyISAM tables
|
||||
--myisam-max-sort-file-size=#
|
||||
Don't use the fast sort index method to created index if
|
||||
the temporary file would get bigger than this
|
||||
--myisam-mmap-size=#
|
||||
Restricts the total memory used for memory mapping of
|
||||
MySQL tables
|
||||
--myisam-recover-options[=name]
|
||||
Syntax: myisam-recover-options[=option[,option...]],
|
||||
where option can be DEFAULT, BACKUP, FORCE, QUICK, or OFF
|
||||
--myisam-repair-threads=#
|
||||
If larger than 1, when repairing a MyISAM table all
|
||||
indexes will be created in parallel, with one thread per
|
||||
index. The value of 1 disables parallel repair
|
||||
--myisam-sort-buffer-size=#
|
||||
The buffer that is allocated when sorting the index when
|
||||
doing a REPAIR or when creating indexes with CREATE INDEX
|
||||
or ALTER TABLE
|
||||
--myisam-stats-method=name
|
||||
Specifies how MyISAM index statistics collection code
|
||||
should treat NULLs. Possible values of name are
|
||||
NULLS_UNEQUAL (default behavior for 4.1 and later),
|
||||
NULLS_EQUAL (emulate 4.0 behavior), and NULLS_IGNORED
|
||||
--myisam-use-mmap Use memory mapping for reading and writing MyISAM tables
|
||||
--named-pipe Enable the named pipe (NT)
|
||||
--net-buffer-length=#
|
||||
Buffer length for TCP/IP and socket communication
|
||||
--net-read-timeout=#
|
||||
Number of seconds to wait for more data from a connection
|
||||
before aborting the read
|
||||
--net-retry-count=# If a read on a communication port is interrupted, retry
|
||||
this many times before giving up
|
||||
--net-write-timeout=#
|
||||
Number of seconds to wait for a block to be written to a
|
||||
connection before aborting the write
|
||||
-n, --new Use very new possible "unsafe" functions
|
||||
--old Use compatible behavior
|
||||
--old-alter-table Use old, non-optimized alter table
|
||||
--old-passwords Use old password encryption method (needed for 4.0 and
|
||||
older clients)
|
||||
--old-style-user-limits
|
||||
Enable old-style user limits (before 5.0.3 user resources
|
||||
were counted per each user+host vs. per account)
|
||||
--one-thread (deprecated): Only use one thread (for debugging under
|
||||
Linux). Use thread-handling=no-threads instead
|
||||
--open-files-limit=#
|
||||
If this is not 0, then mysqld will use this value to
|
||||
reserve file descriptors to use with setrlimit(). If this
|
||||
value is 0 then mysqld will reserve max_connections*5 or
|
||||
max_connections + table_cache*2 (whichever is larger)
|
||||
number of file descriptors
|
||||
--optimizer-prune-level=#
|
||||
Controls the heuristic(s) applied during query
|
||||
optimization to prune less-promising partial plans from
|
||||
the optimizer search space. Meaning: 0 - do not apply any
|
||||
heuristic, thus perform exhaustive search; 1 - prune
|
||||
plans based on number of retrieved rows
|
||||
--optimizer-search-depth=#
|
||||
Maximum depth of search performed by the query optimizer.
|
||||
Values larger than the number of relations in a query
|
||||
result in better query plans, but take longer to compile
|
||||
a query. Values smaller than the number of tables in a
|
||||
relation result in faster optimization, but may produce
|
||||
very bad query plans. If set to 0, the system will
|
||||
automatically pick a reasonable value; if set to 63, the
|
||||
optimizer will switch to the original find_best
|
||||
search(used for testing/comparison)
|
||||
--optimizer-switch=name
|
||||
optimizer_switch=option=val[,option=val...], where option
|
||||
is one of {index_merge, index_merge_union,
|
||||
index_merge_sort_union, index_merge_intersection,
|
||||
engine_condition_pushdown} and val is one of {on, off,
|
||||
default}
|
||||
--partition[=name] Enable or disable partition plugin. Possible values are
|
||||
ON, OFF, FORCE (don't start if the plugin fails to load).
|
||||
--performance-schema
|
||||
Enable the performance schema.
|
||||
--performance-schema-events-waits-history-long-size=#
|
||||
Number of rows in EVENTS_WAITS_HISTORY_LONG.
|
||||
--performance-schema-events-waits-history-size=#
|
||||
Number of rows per thread in EVENTS_WAITS_HISTORY.
|
||||
--performance-schema-max-cond-classes=#
|
||||
Maximum number of condition instruments.
|
||||
--performance-schema-max-cond-instances=#
|
||||
Maximum number of instrumented condition objects.
|
||||
--performance-schema-max-file-classes=#
|
||||
Maximum number of file instruments.
|
||||
--performance-schema-max-file-handles=#
|
||||
Maximum number of opened instrumented files.
|
||||
--performance-schema-max-file-instances=#
|
||||
Maximum number of instrumented files.
|
||||
--performance-schema-max-mutex-classes=#
|
||||
Maximum number of mutex instruments.
|
||||
--performance-schema-max-mutex-instances=#
|
||||
Maximum number of instrumented MUTEX objects.
|
||||
--performance-schema-max-rwlock-classes=#
|
||||
Maximum number of rwlock instruments.
|
||||
--performance-schema-max-rwlock-instances=#
|
||||
Maximum number of instrumented RWLOCK objects.
|
||||
--performance-schema-max-table-handles=#
|
||||
Maximum number of opened instrumented tables.
|
||||
--performance-schema-max-table-instances=#
|
||||
Maximum number of instrumented tables.
|
||||
--performance-schema-max-thread-classes=#
|
||||
Maximum number of thread instruments.
|
||||
--performance-schema-max-thread-instances=#
|
||||
Maximum number of instrumented threads.
|
||||
--pid-file=name Pid file used by safe_mysqld
|
||||
--plugin-dir=name Directory for plugins
|
||||
--plugin-load=name Optional semicolon-separated list of plugins to load,
|
||||
where each plugin is identified as name=library, where
|
||||
name is the plugin name and library is the plugin library
|
||||
in plugin_dir.
|
||||
-P, --port=# Port number to use for connection or 0 to default to,
|
||||
my.cnf, $MYSQL_TCP_PORT, /etc/services, built-in default
|
||||
(3306), whatever comes first
|
||||
--port-open-timeout=#
|
||||
Maximum time in seconds to wait for the port to become
|
||||
free. (Default: no wait)
|
||||
--preload-buffer-size=#
|
||||
The size of the buffer that is allocated when preloading
|
||||
indexes
|
||||
--profiling-history-size=#
|
||||
Limit of query profiling memory
|
||||
--query-alloc-block-size=#
|
||||
Allocation block size for query parsing and execution
|
||||
--query-cache-limit=#
|
||||
Don't cache results that are bigger than this
|
||||
--query-cache-min-res-unit=#
|
||||
The minimum size for blocks allocated by the query cache
|
||||
--query-cache-size=#
|
||||
The memory allocated to store results from old queries
|
||||
--query-cache-type=name
|
||||
OFF = Don't cache or retrieve results. ON = Cache all
|
||||
results except SELECT SQL_NO_CACHE ... queries. DEMAND =
|
||||
Cache only SELECT SQL_CACHE ... queries
|
||||
--query-cache-wlock-invalidate
|
||||
Invalidate queries in query cache on LOCK for write
|
||||
--query-prealloc-size=#
|
||||
Persistent buffer for query parsing and execution
|
||||
--range-alloc-block-size=#
|
||||
Allocation block size for storing ranges during
|
||||
optimization
|
||||
--read-buffer-size=#
|
||||
Each thread that does a sequential scan allocates a
|
||||
buffer of this size for each table it scans. If you do
|
||||
many sequential scans, you may want to increase this
|
||||
value
|
||||
--read-only Make all non-temporary tables read-only, with the
|
||||
exception for replication (slave) threads and users with
|
||||
the SUPER privilege
|
||||
--read-rnd-buffer-size=#
|
||||
When reading rows in sorted order after a sort, the rows
|
||||
are read through this buffer to avoid a disk seeks. If
|
||||
not set, then it's set to the value of record_buffer
|
||||
--record-buffer=# Deprecated; use --read-buffer-size instead.
|
||||
--relay-log=name The location and name to use for relay logs
|
||||
--relay-log-index=name
|
||||
The location and name to use for the file that keeps a
|
||||
list of the last relay logs
|
||||
--relay-log-info-file=name
|
||||
The location and name of the file that remembers where
|
||||
the SQL replication thread is in the relay logs
|
||||
--relay-log-purge if disabled - do not purge relay logs. if enabled - purge
|
||||
them as soon as they are no more needed
|
||||
(Defaults to on; use --skip-relay-log-purge to disable.)
|
||||
--relay-log-recovery
|
||||
Enables automatic relay log recovery right after the
|
||||
database startup, which means that the IO Thread starts
|
||||
re-fetching from the master right after the last
|
||||
transaction processed
|
||||
--relay-log-space-limit=#
|
||||
Maximum space to use for all relay logs
|
||||
--replicate-do-db=name
|
||||
Tells the slave thread to restrict replication to the
|
||||
specified database. To specify more than one database,
|
||||
use the directive multiple times, once for each database.
|
||||
Note that this will only work if you do not use
|
||||
cross-database queries such as UPDATE some_db.some_table
|
||||
SET foo='bar' while having selected a different or no
|
||||
database. If you need cross database updates to work,
|
||||
make sure you have 3.23.28 or later, and use
|
||||
replicate-wild-do-table=db_name.%.
|
||||
--replicate-do-table=name
|
||||
Tells the slave thread to restrict replication to the
|
||||
specified table. To specify more than one table, use the
|
||||
directive multiple times, once for each table. This will
|
||||
work for cross-database updates, in contrast to
|
||||
replicate-do-db.
|
||||
--replicate-ignore-db=name
|
||||
Tells the slave thread to not replicate to the specified
|
||||
database. To specify more than one database to ignore,
|
||||
use the directive multiple times, once for each database.
|
||||
This option will not work if you use cross database
|
||||
updates. If you need cross database updates to work, make
|
||||
sure you have 3.23.28 or later, and use
|
||||
replicate-wild-ignore-table=db_name.%.
|
||||
--replicate-ignore-table=name
|
||||
Tells the slave thread to not replicate to the specified
|
||||
table. To specify more than one table to ignore, use the
|
||||
directive multiple times, once for each table. This will
|
||||
work for cross-datbase updates, in contrast to
|
||||
replicate-ignore-db.
|
||||
--replicate-rewrite-db=name
|
||||
Updates to a database with a different name than the
|
||||
original. Example:
|
||||
replicate-rewrite-db=master_db_name->slave_db_name.
|
||||
--replicate-same-server-id
|
||||
In replication, if set to 1, do not skip events having
|
||||
our server id. Default value is 0 (to break infinite
|
||||
loops in circular replication). Can't be set to 1 if
|
||||
--log-slave-updates is used.
|
||||
--replicate-wild-do-table=name
|
||||
Tells the slave thread to restrict replication to the
|
||||
tables that match the specified wildcard pattern. To
|
||||
specify more than one table, use the directive multiple
|
||||
times, once for each table. This will work for
|
||||
cross-database updates. Example:
|
||||
replicate-wild-do-table=foo%.bar% will replicate only
|
||||
updates to tables in all databases that start with foo
|
||||
and whose table names start with bar.
|
||||
--replicate-wild-ignore-table=name
|
||||
Tells the slave thread to not replicate to the tables
|
||||
that match the given wildcard pattern. To specify more
|
||||
than one table to ignore, use the directive multiple
|
||||
times, once for each table. This will work for
|
||||
cross-database updates. Example:
|
||||
replicate-wild-ignore-table=foo%.bar% will not do updates
|
||||
to tables in databases that start with foo and whose
|
||||
table names start with bar.
|
||||
--report-host=name Hostname or IP of the slave to be reported to the master
|
||||
during slave registration. Will appear in the output of
|
||||
SHOW SLAVE HOSTS. Leave unset if you do not want the
|
||||
slave to register itself with the master. Note that it is
|
||||
not sufficient for the master to simply read the IP of
|
||||
the slave off the socket once the slave connects. Due to
|
||||
NAT and other routing issues, that IP may not be valid
|
||||
for connecting to the slave from the master or other
|
||||
hosts
|
||||
--report-password=name
|
||||
The account password of the slave to be reported to the
|
||||
master during slave registration
|
||||
--report-port=# Port for connecting to slave reported to the master
|
||||
during slave registration. Set it only if the slave is
|
||||
listening on a non-default port or if you have a special
|
||||
tunnel from the master or other clients to the slave. If
|
||||
not sure, leave this option unset
|
||||
--report-user=name The account user name of the slave to be reported to the
|
||||
master during slave registration
|
||||
--rpl-recovery-rank=#
|
||||
Unused, will be removed
|
||||
--safe-mode Skip some optimize stages (for testing).
|
||||
--safe-show-database
|
||||
Deprecated option; use GRANT SHOW DATABASES instead...
|
||||
--safe-user-create Don't allow new user creation by the user who has no
|
||||
write privileges to the mysql.user table.
|
||||
--secure-auth Disallow authentication for accounts that have old
|
||||
(pre-4.1) passwords
|
||||
--secure-file-priv=name
|
||||
Limit LOAD DATA, SELECT ... OUTFILE, and LOAD_FILE() to
|
||||
files within specified directory
|
||||
--server-id=# Uniquely identifies the server instance in the community
|
||||
of replication partners
|
||||
-O, --set-variable=name
|
||||
Change the value of a variable. Please note that this
|
||||
option is deprecated;you can set variables directly with
|
||||
--variable-name=value.
|
||||
--shared-memory Enable the shared memory
|
||||
--shared-memory-base-name=name
|
||||
Base name of shared memory
|
||||
--show-slave-auth-info
|
||||
Show user and password in SHOW SLAVE HOSTS on this master
|
||||
--skip-grant-tables Start without grant tables. This gives all users FULL
|
||||
ACCESS to all tables!
|
||||
--skip-host-cache Don't cache host names.
|
||||
--skip-locking Deprecated option, use --skip-external-locking instead.
|
||||
--skip-name-resolve Don't resolve hostnames. All hostnames are IP's or
|
||||
'localhost'.
|
||||
--skip-networking Don't allow connection with TCP/IP
|
||||
--skip-new Don't use new, possible wrong routines.
|
||||
--skip-show-database
|
||||
Don't allow 'SHOW DATABASE' commands
|
||||
--skip-slave-start If set, slave is not autostarted.
|
||||
--skip-stack-trace Don't print a stack trace on failure.
|
||||
--skip-symlink Don't allow symlinking of tables. Deprecated option. Use
|
||||
--skip-symbolic-links instead.
|
||||
--skip-thread-priority
|
||||
Don't give threads different priorities. This option is
|
||||
deprecated because it has no effect; the implied behavior
|
||||
is already the default.
|
||||
--slave-compressed-protocol
|
||||
Use compression on master/slave protocol
|
||||
--slave-exec-mode=name
|
||||
Modes for how replication events should be executed.
|
||||
Legal values are STRICT (default) and IDEMPOTENT. In
|
||||
IDEMPOTENT mode, replication will not stop for operations
|
||||
that are idempotent. In STRICT mode, replication will
|
||||
stop on any unexpected difference between the master and
|
||||
the slave
|
||||
--slave-load-tmpdir=name
|
||||
The location where the slave should put its temporary
|
||||
files when replicating a LOAD DATA INFILE command
|
||||
--slave-net-timeout=#
|
||||
Number of seconds to wait for more data from a
|
||||
master/slave connection before aborting the read
|
||||
--slave-skip-errors=name
|
||||
Tells the slave thread to continue replication when a
|
||||
query event returns an error from the provided list
|
||||
--slave-transaction-retries=#
|
||||
Number of times the slave SQL thread will retry a
|
||||
transaction in case it failed with a deadlock or elapsed
|
||||
lock wait timeout, before giving up and stopping
|
||||
--slave-type-conversions=name
|
||||
Set of slave type conversions that are enabled. Legal
|
||||
values are: ALL_LOSSY to enable lossy conversions and
|
||||
ALL_NON_LOSSY to enable non-lossy conversions. If the
|
||||
variable is assigned the empty set, no conversions are
|
||||
allowed and it is expected that the types match exactly.
|
||||
--slow-launch-time=#
|
||||
If creating the thread takes longer than this value (in
|
||||
seconds), the Slow_launch_threads counter will be
|
||||
incremented
|
||||
--slow-query-log Log slow queries to a table or log file. Defaults logging
|
||||
to a file hostname-slow.log or a table mysql.slow_log if
|
||||
--log-output=TABLE is used. Must be enabled to activate
|
||||
other slow log options
|
||||
--slow-query-log-file=name
|
||||
Log slow queries to given log file. Defaults logging to
|
||||
hostname-slow.log. Must be enabled to activate other slow
|
||||
log options
|
||||
--socket=name Socket file to use for connection
|
||||
--sort-buffer-size=#
|
||||
Each thread that needs to do a sort allocates a buffer of
|
||||
this size
|
||||
--sporadic-binlog-dump-fail
|
||||
Option used by mysql-test for debugging and testing of
|
||||
replication.
|
||||
--sql-bin-update-same
|
||||
The update log is deprecated since version 5.0, is
|
||||
replaced by the binary log and this option does nothing
|
||||
anymore.
|
||||
--sql-mode=name Syntax: sql-mode=mode[,mode[,mode...]]. See the manual
|
||||
for the complete list of valid sql modes
|
||||
--standalone Dummy option to start as a standalone program (NT).
|
||||
-s, --symbolic-links
|
||||
Enable symbolic link support.
|
||||
--sync-binlog=# Synchronously flush binary log to disk after every #th
|
||||
event. Use 0 (default) to disable synchronous flushing
|
||||
--sync-frm Sync .frm files to disk on creation
|
||||
(Defaults to on; use --skip-sync-frm to disable.)
|
||||
--sync-master-info=#
|
||||
Synchronously flush master info to disk after every #th
|
||||
event. Use 0 (default) to disable synchronous flushing
|
||||
--sync-relay-log=# Synchronously flush relay log to disk after every #th
|
||||
event. Use 0 (default) to disable synchronous flushing
|
||||
--sync-relay-log-info=#
|
||||
Synchronously flush relay log info to disk after every
|
||||
#th transaction. Use 0 (default) to disable synchronous
|
||||
flushing
|
||||
--sysdate-is-now Non-default option to alias SYSDATE() to NOW() to make it
|
||||
safe-replicable. Since 5.0, SYSDATE() returns a `dynamic'
|
||||
value different for different invocations, even within
|
||||
the same statement.
|
||||
--table-cache=# Deprecated; use --table-open-cache instead.
|
||||
--table-definition-cache=#
|
||||
The number of cached table definitions
|
||||
--table-lock-wait-timeout=#
|
||||
Timeout in seconds to wait for a table level lock before
|
||||
returning an error. Used only if the connection has
|
||||
active cursors
|
||||
--table-open-cache=#
|
||||
The number of cached open tables
|
||||
--tc-heuristic-recover=name
|
||||
Decision to use in heuristic recover process. Possible
|
||||
values are COMMIT or ROLLBACK.
|
||||
--thread-cache-size=#
|
||||
How many threads we should keep in a cache for reuse
|
||||
--thread-handling=name
|
||||
Define threads usage for handling queries, one of
|
||||
one-thread-per-connection, no-threads
|
||||
--thread-stack=# The stack size for each thread
|
||||
--time-format=name The TIME format (ignored)
|
||||
--timed-mutexes Specify whether to time mutexes (only InnoDB mutexes are
|
||||
currently supported)
|
||||
--tmp-table-size=# If an internal in-memory temporary table exceeds this
|
||||
size, MySQL will automatically convert it to an on-disk
|
||||
MyISAM table
|
||||
-t, --tmpdir=name Path for temporary files. Several paths may be specified,
|
||||
separated by a semicolon (;), in this case they are used
|
||||
in a round-robin fashion
|
||||
--transaction-alloc-block-size=#
|
||||
Allocation block size for transactions to be stored in
|
||||
binary log
|
||||
--transaction-isolation=name
|
||||
Default transaction isolation level.
|
||||
--transaction-prealloc-size=#
|
||||
Persistent buffer for transactions to be stored in binary
|
||||
log
|
||||
--updatable-views-with-limit=name
|
||||
YES = Don't issue an error message (warning only) if a
|
||||
VIEW without presence of a key of the underlying table is
|
||||
used in queries with a LIMIT clause for updating. NO =
|
||||
Prohibit update of a VIEW, which does not contain a key
|
||||
of the underlying table and the query uses a LIMIT clause
|
||||
(usually get from GUI tools)
|
||||
-s, --use-symbolic-links
|
||||
Enable symbolic link support. Deprecated option; use
|
||||
--symbolic-links instead.
|
||||
-u, --user=name Run mysqld daemon as user.
|
||||
-v, --verbose Used with --help option for detailed help
|
||||
-V, --version Output version information and exit.
|
||||
--wait-timeout=# The number of seconds the server waits for activity on a
|
||||
connection before closing it
|
||||
-W, --warnings[=#] Deprecated; use --log-warnings instead.
|
||||
|
||||
Variables (--variable-name=value)
|
||||
and boolean options {FALSE|TRUE} Value (after reading options)
|
||||
------------------------------------------------- ------------------------
|
||||
abort-slave-event-count 0
|
||||
allow-suspicious-udfs FALSE
|
||||
archive ON
|
||||
auto-increment-increment 1
|
||||
auto-increment-offset 1
|
||||
automatic-sp-privileges TRUE
|
||||
back-log 50
|
||||
big-tables FALSE
|
||||
bind-address (No default value)
|
||||
binlog-cache-size 32768
|
||||
binlog-format STATEMENT
|
||||
binlog-row-event-max-size 1024
|
||||
blackhole ON
|
||||
bulk-insert-buffer-size 8388608
|
||||
character-set-client-handshake TRUE
|
||||
character-set-filesystem binary
|
||||
character-set-server latin1
|
||||
character-sets-dir MYSQL_SHAREDIR/charsets/
|
||||
chroot (No default value)
|
||||
collation-server latin1_swedish_ci
|
||||
completion-type NO_CHAIN
|
||||
concurrent-insert AUTO
|
||||
connect-timeout 10
|
||||
console FALSE
|
||||
date-format %Y-%m-%d
|
||||
datetime-format %Y-%m-%d %H:%i:%s
|
||||
default-character-set latin1
|
||||
default-collation latin1_swedish_ci
|
||||
default-storage-engine MyISAM
|
||||
default-time-zone (No default value)
|
||||
default-week-format 0
|
||||
delay-key-write ON
|
||||
delayed-insert-limit 100
|
||||
delayed-insert-timeout 300
|
||||
delayed-queue-size 1000
|
||||
disconnect-slave-event-count 0
|
||||
div-precision-increment 4
|
||||
enable-locking FALSE
|
||||
engine-condition-pushdown TRUE
|
||||
event-scheduler OFF
|
||||
expire-logs-days 0
|
||||
external-locking FALSE
|
||||
federated ON
|
||||
flush FALSE
|
||||
flush-time 1800
|
||||
ft-boolean-syntax + -><()~*:""&|
|
||||
ft-max-word-len 84
|
||||
ft-min-word-len 4
|
||||
ft-query-expansion-limit 20
|
||||
ft-stopword-file (No default value)
|
||||
gdb FALSE
|
||||
general-log FALSE
|
||||
group-concat-max-len 1024
|
||||
help TRUE
|
||||
ignore-builtin-innodb FALSE
|
||||
init-connect
|
||||
init-file (No default value)
|
||||
init-rpl-role MASTER
|
||||
init-slave
|
||||
interactive-timeout 28800
|
||||
join-buffer-size 131072
|
||||
keep-files-on-create FALSE
|
||||
key-buffer-size 8388608
|
||||
key-cache-age-threshold 300
|
||||
key-cache-block-size 1024
|
||||
key-cache-division-limit 100
|
||||
language MYSQL_SHAREDIR/
|
||||
lc-messages en_US
|
||||
lc-messages-dir MYSQL_SHAREDIR/
|
||||
lc-time-names en_US
|
||||
local-infile TRUE
|
||||
log-bin (No default value)
|
||||
log-bin-index (No default value)
|
||||
log-bin-trust-function-creators FALSE
|
||||
log-error
|
||||
log-isam myisam.log
|
||||
log-output FILE
|
||||
log-queries-not-using-indexes FALSE
|
||||
log-short-format FALSE
|
||||
log-slave-updates FALSE
|
||||
log-slow-admin-statements FALSE
|
||||
log-slow-slave-statements FALSE
|
||||
log-tc tc.log
|
||||
log-tc-size 24576
|
||||
log-update (No default value)
|
||||
log-warnings 1
|
||||
long-query-time 10
|
||||
low-priority-updates FALSE
|
||||
lower-case-table-names 1
|
||||
master-info-file master.info
|
||||
master-retry-count 86400
|
||||
max-allowed-packet 1048576
|
||||
max-binlog-cache-size 18446744073709547520
|
||||
max-binlog-dump-events 0
|
||||
max-binlog-size 1073741824
|
||||
max-connect-errors 10
|
||||
max-connections 151
|
||||
max-delayed-threads 20
|
||||
max-error-count 64
|
||||
max-heap-table-size 16777216
|
||||
max-join-size 18446744073709551615
|
||||
max-length-for-sort-data 1024
|
||||
max-prepared-stmt-count 16382
|
||||
max-relay-log-size 0
|
||||
max-seeks-for-key 18446744073709551615
|
||||
max-sort-length 1024
|
||||
max-sp-recursion-depth 0
|
||||
max-tmp-tables 32
|
||||
max-user-connections 0
|
||||
max-write-lock-count 18446744073709551615
|
||||
memlock FALSE
|
||||
min-examined-row-limit 0
|
||||
multi-range-count 256
|
||||
myisam-block-size 1024
|
||||
myisam-data-pointer-size 6
|
||||
myisam-max-sort-file-size 9223372036853727232
|
||||
myisam-mmap-size 18446744073709551615
|
||||
myisam-recover-options OFF
|
||||
myisam-repair-threads 1
|
||||
myisam-sort-buffer-size 8388608
|
||||
myisam-stats-method nulls_unequal
|
||||
myisam-use-mmap FALSE
|
||||
named-pipe FALSE
|
||||
net-buffer-length 16384
|
||||
net-read-timeout 30
|
||||
net-retry-count 10
|
||||
net-write-timeout 60
|
||||
new FALSE
|
||||
old FALSE
|
||||
old-alter-table FALSE
|
||||
old-passwords FALSE
|
||||
old-style-user-limits FALSE
|
||||
optimizer-prune-level 1
|
||||
optimizer-search-depth 62
|
||||
optimizer-switch index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
partition ON
|
||||
performance-schema FALSE
|
||||
performance-schema-events-waits-history-long-size 10000
|
||||
performance-schema-events-waits-history-size 10
|
||||
performance-schema-max-cond-classes 80
|
||||
performance-schema-max-cond-instances 1000
|
||||
performance-schema-max-file-classes 50
|
||||
performance-schema-max-file-handles 32768
|
||||
performance-schema-max-file-instances 10000
|
||||
performance-schema-max-mutex-classes 200
|
||||
performance-schema-max-mutex-instances 1000
|
||||
performance-schema-max-rwlock-classes 20
|
||||
performance-schema-max-rwlock-instances 1000
|
||||
performance-schema-max-table-handles 100000
|
||||
performance-schema-max-table-instances 50000
|
||||
performance-schema-max-thread-classes 50
|
||||
performance-schema-max-thread-instances 1000
|
||||
plugin-dir MYSQL_LIBDIR/plugin
|
||||
plugin-load (No default value)
|
||||
port 3306
|
||||
port-open-timeout 0
|
||||
preload-buffer-size 32768
|
||||
profiling-history-size 15
|
||||
query-alloc-block-size 8192
|
||||
query-cache-limit 1048576
|
||||
query-cache-min-res-unit 4096
|
||||
query-cache-size 0
|
||||
query-cache-type ON
|
||||
query-cache-wlock-invalidate FALSE
|
||||
query-prealloc-size 8192
|
||||
range-alloc-block-size 4096
|
||||
read-buffer-size 131072
|
||||
read-only FALSE
|
||||
read-rnd-buffer-size 262144
|
||||
record-buffer 131072
|
||||
relay-log (No default value)
|
||||
relay-log-index (No default value)
|
||||
relay-log-info-file relay-log.info
|
||||
relay-log-purge TRUE
|
||||
relay-log-recovery FALSE
|
||||
relay-log-space-limit 0
|
||||
replicate-same-server-id FALSE
|
||||
report-host (No default value)
|
||||
report-password (No default value)
|
||||
report-port 3306
|
||||
report-user (No default value)
|
||||
rpl-recovery-rank 0
|
||||
safe-user-create FALSE
|
||||
secure-auth FALSE
|
||||
secure-file-priv (No default value)
|
||||
server-id 0
|
||||
shared-memory FALSE
|
||||
shared-memory-base-name MYSQL
|
||||
show-slave-auth-info FALSE
|
||||
skip-grant-tables TRUE
|
||||
skip-networking FALSE
|
||||
skip-show-database FALSE
|
||||
skip-slave-start FALSE
|
||||
slave-compressed-protocol FALSE
|
||||
slave-exec-mode STRICT
|
||||
slave-net-timeout 3600
|
||||
slave-skip-errors (No default value)
|
||||
slave-transaction-retries 10
|
||||
slave-type-conversions
|
||||
slow-launch-time 2
|
||||
slow-query-log FALSE
|
||||
socket MySQL
|
||||
sort-buffer-size 2097152
|
||||
sporadic-binlog-dump-fail FALSE
|
||||
sql-mode
|
||||
symbolic-links FALSE
|
||||
sync-binlog 0
|
||||
sync-frm TRUE
|
||||
sync-master-info 0
|
||||
sync-relay-log 0
|
||||
sync-relay-log-info 0
|
||||
sysdate-is-now FALSE
|
||||
table-cache 400
|
||||
table-definition-cache 400
|
||||
table-lock-wait-timeout 50
|
||||
table-open-cache 400
|
||||
tc-heuristic-recover COMMIT
|
||||
thread-cache-size 0
|
||||
thread-handling one-thread-per-connection
|
||||
thread-stack 262144
|
||||
time-format %H:%i:%s
|
||||
timed-mutexes FALSE
|
||||
tmp-table-size 16777216
|
||||
transaction-alloc-block-size 8192
|
||||
transaction-isolation REPEATABLE-READ
|
||||
transaction-prealloc-size 4096
|
||||
updatable-views-with-limit YES
|
||||
use-symbolic-links FALSE
|
||||
verbose TRUE
|
||||
wait-timeout 28800
|
||||
warnings 1
|
||||
|
||||
To see what values a running MySQL server is using, type
|
||||
'mysqladmin variables' instead of 'mysqld --verbose --help'.
|
||||
@@ -55,7 +55,7 @@ CREATE TABLE `t1` (
|
||||
`a` double DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||
INSERT INTO `t1` VALUES (RES);
|
||||
INSERT INTO `t1` VALUES (-1.7976931348623157e308);
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug#3361 mysqldump quotes DECIMAL values inconsistently
|
||||
|
||||
@@ -1,47 +1,47 @@
|
||||
DROP TABLE IF EXISTS t1;
|
||||
FLUSH TABLES;
|
||||
SELECT * FROM t1;
|
||||
ERROR 42000: Unknown table engine 'partition'
|
||||
ERROR 42000: Unknown storage engine 'partition'
|
||||
TRUNCATE TABLE t1;
|
||||
ERROR 42000: Unknown table engine 'partition'
|
||||
ERROR 42000: Unknown storage engine 'partition'
|
||||
ANALYZE TABLE t1;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 analyze Error Unknown table engine 'partition'
|
||||
test.t1 analyze Error Unknown storage engine 'partition'
|
||||
test.t1 analyze error Corrupt
|
||||
CHECK TABLE t1;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 check Error Unknown table engine 'partition'
|
||||
test.t1 check Error Unknown storage engine 'partition'
|
||||
test.t1 check error Corrupt
|
||||
OPTIMIZE TABLE t1;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 optimize Error Unknown table engine 'partition'
|
||||
test.t1 optimize Error Unknown storage engine 'partition'
|
||||
test.t1 optimize error Corrupt
|
||||
REPAIR TABLE t1;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 repair Error Unknown table engine 'partition'
|
||||
test.t1 repair Error Unknown storage engine 'partition'
|
||||
test.t1 repair error Corrupt
|
||||
ALTER TABLE t1 REPAIR PARTITION ALL;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 repair Error Unknown table engine 'partition'
|
||||
test.t1 repair Error Unknown storage engine 'partition'
|
||||
test.t1 repair error Corrupt
|
||||
ALTER TABLE t1 CHECK PARTITION ALL;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 check Error Unknown table engine 'partition'
|
||||
test.t1 check Error Unknown storage engine 'partition'
|
||||
test.t1 check error Corrupt
|
||||
ALTER TABLE t1 OPTIMIZE PARTITION ALL;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 optimize Error Unknown table engine 'partition'
|
||||
test.t1 optimize Error Unknown storage engine 'partition'
|
||||
test.t1 optimize error Corrupt
|
||||
ALTER TABLE t1 ANALYZE PARTITION ALL;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 analyze Error Unknown table engine 'partition'
|
||||
test.t1 analyze Error Unknown storage engine 'partition'
|
||||
test.t1 analyze error Corrupt
|
||||
ALTER TABLE t1 REBUILD PARTITION ALL;
|
||||
ERROR 42000: Unknown table engine 'partition'
|
||||
ERROR 42000: Unknown storage engine 'partition'
|
||||
ALTER TABLE t1 ENGINE Memory;
|
||||
ERROR 42000: Unknown table engine 'partition'
|
||||
ERROR 42000: Unknown storage engine 'partition'
|
||||
ALTER TABLE t1 ADD (new INT);
|
||||
ERROR 42000: Unknown table engine 'partition'
|
||||
ERROR 42000: Unknown storage engine 'partition'
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (
|
||||
firstname VARCHAR(25) NOT NULL,
|
||||
@@ -52,9 +52,9 @@ joined DATE NOT NULL
|
||||
)
|
||||
PARTITION BY KEY(joined)
|
||||
PARTITIONS 6;
|
||||
Got one of the listed errors
|
||||
ERROR HY000: The 'partitioning' feature is disabled; you need MySQL built with '--with-plugin-partition' to have it working
|
||||
ALTER TABLE t1 PARTITION BY KEY(joined) PARTITIONS 2;
|
||||
Got one of the listed errors
|
||||
ERROR HY000: The 'partitioning' feature is disabled; you need MySQL built with '--with-plugin-partition' to have it working
|
||||
drop table t1;
|
||||
ERROR 42S02: Unknown table 't1'
|
||||
CREATE TABLE t1 (
|
||||
@@ -71,7 +71,7 @@ PARTITION p2 VALUES LESS THAN (1980),
|
||||
PARTITION p3 VALUES LESS THAN (1990),
|
||||
PARTITION p4 VALUES LESS THAN MAXVALUE
|
||||
);
|
||||
Got one of the listed errors
|
||||
ERROR HY000: The 'partitioning' feature is disabled; you need MySQL built with '--with-plugin-partition' to have it working
|
||||
drop table t1;
|
||||
ERROR 42S02: Unknown table 't1'
|
||||
CREATE TABLE t1 (id INT, purchased DATE)
|
||||
@@ -82,7 +82,7 @@ PARTITION p0 VALUES LESS THAN (1990),
|
||||
PARTITION p1 VALUES LESS THAN (2000),
|
||||
PARTITION p2 VALUES LESS THAN MAXVALUE
|
||||
);
|
||||
Got one of the listed errors
|
||||
ERROR HY000: The 'partitioning' feature is disabled; you need MySQL built with '--with-plugin-partition' to have it working
|
||||
drop table t1;
|
||||
ERROR 42S02: Unknown table 't1'
|
||||
create table t1 (a varchar(10) charset latin1 collate latin1_bin);
|
||||
|
||||
5
mysql-test/r/optimizer_switch_eng_cond_pushdown1.result
Normal file
5
mysql-test/r/optimizer_switch_eng_cond_pushdown1.result
Normal file
@@ -0,0 +1,5 @@
|
||||
select @@session.engine_condition_pushdown,
|
||||
@@global.engine_condition_pushdown,
|
||||
@@session.optimizer_switch, @@global.optimizer_switch;
|
||||
@@session.engine_condition_pushdown @@global.engine_condition_pushdown @@session.optimizer_switch @@global.optimizer_switch
|
||||
1 1 index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=on
|
||||
5
mysql-test/r/optimizer_switch_eng_cond_pushdown2.result
Normal file
5
mysql-test/r/optimizer_switch_eng_cond_pushdown2.result
Normal file
@@ -0,0 +1,5 @@
|
||||
select @@session.engine_condition_pushdown,
|
||||
@@global.engine_condition_pushdown,
|
||||
@@session.optimizer_switch, @@global.optimizer_switch;
|
||||
@@session.engine_condition_pushdown @@global.engine_condition_pushdown @@session.optimizer_switch @@global.optimizer_switch
|
||||
0 0 index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=off index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,engine_condition_pushdown=off
|
||||
@@ -522,7 +522,7 @@ select conv(255 AS p1, 10 AS p2, 16 AS p3);
|
||||
ERROR 42000: Incorrect parameters in the call to native function 'conv'
|
||||
select atan(10);
|
||||
atan(10)
|
||||
1.47112767430373
|
||||
1.4711276743037347
|
||||
select atan(10 AS p1);
|
||||
ERROR 42000: Incorrect parameters in the call to native function 'atan'
|
||||
select atan(10 p1);
|
||||
@@ -533,7 +533,7 @@ select atan(10 "p1");
|
||||
ERROR 42000: Incorrect parameters in the call to native function 'atan'
|
||||
select atan(10, 20);
|
||||
atan(10, 20)
|
||||
0.463647609000806
|
||||
0.4636476090008061
|
||||
select atan(10 AS p1, 20);
|
||||
ERROR 42000: Incorrect parameters in the call to native function 'atan'
|
||||
select atan(10 p1, 20);
|
||||
|
||||
@@ -97,30 +97,30 @@ DROP TABLE t1;
|
||||
CREATE TABLE t1 (a INT)
|
||||
ENGINE=NonExistentEngine;
|
||||
Warnings:
|
||||
Warning 1286 Unknown table engine 'NonExistentEngine'
|
||||
Warning 1286 Unknown storage engine 'NonExistentEngine'
|
||||
Warning 1266 Using storage engine MyISAM for table 't1'
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (a INT)
|
||||
ENGINE=NonExistentEngine
|
||||
PARTITION BY HASH (a);
|
||||
Warnings:
|
||||
Warning 1286 Unknown table engine 'NonExistentEngine'
|
||||
Warning 1286 Unknown storage engine 'NonExistentEngine'
|
||||
Warning 1266 Using storage engine MyISAM for table 't1'
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (a INT)
|
||||
ENGINE=Memory;
|
||||
ALTER TABLE t1 ENGINE=NonExistentEngine;
|
||||
Warnings:
|
||||
Warning 1286 Unknown table engine 'NonExistentEngine'
|
||||
Warning 1286 Unknown storage engine 'NonExistentEngine'
|
||||
ALTER TABLE t1
|
||||
PARTITION BY HASH (a)
|
||||
(PARTITION p0 ENGINE=Memory,
|
||||
PARTITION p1 ENGINE=NonExistentEngine);
|
||||
Warnings:
|
||||
Warning 1286 Unknown table engine 'NonExistentEngine'
|
||||
Warning 1286 Unknown storage engine 'NonExistentEngine'
|
||||
ALTER TABLE t1 ENGINE=NonExistentEngine;
|
||||
Warnings:
|
||||
Warning 1286 Unknown table engine 'NonExistentEngine'
|
||||
Warning 1286 Unknown storage engine 'NonExistentEngine'
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
|
||||
@@ -196,7 +196,7 @@ create table t1 (a int)
|
||||
engine = x
|
||||
partition by key (a);
|
||||
Warnings:
|
||||
Warning 1286 Unknown table engine 'x'
|
||||
Warning 1286 Unknown storage engine 'x'
|
||||
Warning 1266 Using storage engine MyISAM for table 't1'
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
@@ -211,7 +211,7 @@ partition by list (a)
|
||||
(partition p0 values in (0));
|
||||
alter table t1 engine = x;
|
||||
Warnings:
|
||||
Warning 1286 Unknown table engine 'x'
|
||||
Warning 1286 Unknown storage engine 'x'
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
|
||||
@@ -42,7 +42,7 @@ id
|
||||
SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
|
||||
BEGIN;
|
||||
INSERT INTO t1 VALUES(9);
|
||||
ERROR HY000: Binary logging not possible. Message: Transaction level 'READ-COMMITTED' in InnoDB is not safe for binlog mode 'STATEMENT'
|
||||
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.
|
||||
COMMIT;
|
||||
COMMIT;
|
||||
DROP TABLE t1;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user