summaryrefslogtreecommitdiff
path: root/mysql-test/r/rpl_multi_update.result
diff options
context:
space:
mode:
authorunknown <guilhem@mysql.com>2003-12-04 22:42:18 +0100
committerunknown <guilhem@mysql.com>2003-12-04 22:42:18 +0100
commit66927c51fa8e25f9d8a9d818f4ff7ed2a64c5ecb (patch)
treeca8ac74120edb9722c802f5ad77a4b4ecdae17d2 /mysql-test/r/rpl_multi_update.result
parent0a9ae10f9e3087ace610b2cfa508eb280f3dd7ad (diff)
downloadmariadb-git-66927c51fa8e25f9d8a9d818f4ff7ed2a64c5ecb.tar.gz
- Fix for BUG#1858 "SQL-Thread stops working when using optimize table":
we change THD::system_thread from a 'bool' to a bitmap to be able to distinguish between delayed-insert threads and slave threads. - Fix for BUG#1701 "Update from multiple tables" (one line in sql_parse.cc, plus a new test rpl_multi_update.test). That's just adding an initialization. sql/repl_failsafe.cc: comment to warn about this unused code sql/slave.cc: Now thd->system_thread is a bitmap, not a bool. sql/sql_class.h: 'bool' for THD::system_thread is not accurate enough; sometimes we need to distinguish between delayed-insert threads and slave threads; so changing THD::system_thread to a bitmap (uint). sql/sql_insert.cc: thd.system_thread is now a bitmap sql/sql_parse.cc: We need to initialize thd->lex.select_lex.options in mysql_init_query(); it's already initialized in dispatch_command() but replication calls mysql_parse() directly, thus bypassing dispatch_command(). Not initing it here leads to a query influencing the next query, in the slave SQL thread. The initialization in dispatch_command() must be kept as this command uses the variable in tests, even when the command was not a query (i.e. when mysql_init_query() was not called).
Diffstat (limited to 'mysql-test/r/rpl_multi_update.result')
-rw-r--r--mysql-test/r/rpl_multi_update.result27
1 files changed, 27 insertions, 0 deletions
diff --git a/mysql-test/r/rpl_multi_update.result b/mysql-test/r/rpl_multi_update.result
new file mode 100644
index 00000000000..1fa1dd104d2
--- /dev/null
+++ b/mysql-test/r/rpl_multi_update.result
@@ -0,0 +1,27 @@
+slave stop;
+drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
+reset master;
+reset slave;
+drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
+slave start;
+drop table if exists t1,t2;
+CREATE TABLE t1 (
+a int unsigned not null auto_increment primary key,
+b int unsigned,
+) TYPE=MyISAM;
+CREATE TABLE t2 (
+a int unsigned not null auto_increment primary key,
+b int unsigned
+) TYPE=MyISAM;
+INSERT INTO t1 VALUES (NULL, 0);
+INSERT INTO t1 SELECT NULL, 0 FROM t1;
+INSERT INTO t2 VALUES (NULL, 0), (NULL,1);
+SELECT * FROM t1 ORDER BY a;
+a b
+1 0
+2 0
+SELECT * FROM t2 ORDER BY a;
+a b
+1 0
+2 1
+UPDATE t1, t2 SET t1.b = t2.b WHERE t1.a = t2.a;