MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:Olav Sandstaa Date:February 26 2010 9:21am
Subject:bzr push into mysql-6.0-codebase-bugfixing branch (olav:2968 to 2970)
View as plain text  
 2970 Olav Sandstaa	2010-02-26
      Test cases for the following "ICP for InnoDB" bugs:
                        
      Bug#40992 InnoDB: Crash when engine_condition_pushdown is on
      Bug#35080 Innodb crash at mem_block_get_len line 72
      Bug#41996 multi-table delete crashes server (InnoDB table)
      Bug#43448 Server crashes on multi table delete with Innodb
                        
      All these bugs are duplicates of either one or both of Bug 43360 or 36981.
     @ mysql-test/include/icp_tests.inc
        Test cases for the following "ICP for InnoDB" bugs:
                          
        Bug#40992 InnoDB: Crash when engine_condition_pushdown is on
        Bug#35080 Innodb crash at mem_block_get_len line 72
        Bug#41996 multi-table delete crashes server (InnoDB table)
        Bug#43448 Server crashes on multi table delete with Innodb
                          
        All these bugs are duplicates of either one or both of Bug 43360 or 36981.
     @ mysql-test/r/innodb_icp.result
        Results file for the following "ICP for InnoDB" bugs:
                          
        Bug#40992 InnoDB: Crash when engine_condition_pushdown is on
        Bug#35080 Innodb crash at mem_block_get_len line 72
        Bug#41996 multi-table delete crashes server (InnoDB table)
        Bug#43448 Server crashes on multi table delete with Innodb
     @ mysql-test/r/myisam_icp.result
        Results file for the following "ICP for InnoDB" bugs:
                          
        Bug#40992 InnoDB: Crash when engine_condition_pushdown is on
        Bug#35080 Innodb crash at mem_block_get_len line 72
        Bug#41996 multi-table delete crashes server (InnoDB table)
        Bug#43448 Server crashes on multi table delete with Innodb
     @ mysql-test/suite/optimizer_unfixed_bugs/r/bug40992.result
        Included in include/icp_tests.inc.
     @ mysql-test/suite/optimizer_unfixed_bugs/r/bug41996.result
        Included in include/icp_tests.inc.
     @ mysql-test/suite/optimizer_unfixed_bugs/r/bug43448.result
        Included in include/icp_tests.inc.
     @ mysql-test/suite/optimizer_unfixed_bugs/t/bug40992.test
        Included in include/icp_tests.inc.
     @ mysql-test/suite/optimizer_unfixed_bugs/t/bug41996.test
        Included in include/icp_tests.inc.
     @ mysql-test/suite/optimizer_unfixed_bugs/t/bug43448.test
        Included in include/icp_tests.inc.

    removed:
      mysql-test/suite/optimizer_unfixed_bugs/r/bug40992.result
      mysql-test/suite/optimizer_unfixed_bugs/r/bug41996.result
      mysql-test/suite/optimizer_unfixed_bugs/r/bug43448.result
      mysql-test/suite/optimizer_unfixed_bugs/t/bug40992.test
      mysql-test/suite/optimizer_unfixed_bugs/t/bug41996.test
      mysql-test/suite/optimizer_unfixed_bugs/t/bug43448.test
    modified:
      mysql-test/include/icp_tests.inc
      mysql-test/r/innodb_icp.result
      mysql-test/r/myisam_icp.result
 2969 Olav Sandstaa	2010-02-26
      Testcase for Bug#43360 Server crash with a simple multi-table update (InnoDB table).
      
      The code for fixing the actual bug is included in the patch for Bug#36981.
     @ mysql-test/include/icp_tests.inc
        Testcase for Bug#43360 Server crash with a simple multi-table update (InnoDB table).
     @ mysql-test/r/innodb_icp.result
        Result file for test for Bug#43360.
     @ mysql-test/r/myisam_icp.result
        Result file for test for Bug#43360.
     @ mysql-test/suite/optimizer_unfixed_bugs/r/bug43360.result
        Test is now included in include/icp_tests.inc.
     @ mysql-test/suite/optimizer_unfixed_bugs/t/bug43360.test
        Test is now included in include/icp_tests.inc.

    removed:
      mysql-test/suite/optimizer_unfixed_bugs/r/bug43360.result
      mysql-test/suite/optimizer_unfixed_bugs/t/bug43360.test
    modified:
      mysql-test/include/icp_tests.inc
      mysql-test/r/innodb_icp.result
      mysql-test/r/myisam_icp.result
 2968 Alexander Nozdrin	2010-02-26 [merge]
      Auto-merge from mysql-next-mr-bugfixing.

=== modified file 'mysql-test/include/icp_tests.inc'
--- a/mysql-test/include/icp_tests.inc	2010-02-25 12:55:31 +0000
+++ b/mysql-test/include/icp_tests.inc	2010-02-26 09:19:30 +0000
@@ -55,3 +55,182 @@ INSERT INTO t3
 SELECT c1,c3 FROM t3 WHERE c1 >= 'c-1994=w' and c1 != 'c-1996=w' FOR UPDATE;
 
 DROP TABLE t1,t2,t3;
+
+--echo #
+--echo # Bug#43360 - Server crash with a simple multi-table update
+--echo #
+
+CREATE TABLE t1 (
+  a CHAR(2) NOT NULL PRIMARY KEY, 
+  b VARCHAR(20) NOT NULL,
+  KEY (b)
+);
+
+CREATE TABLE t2 (
+  a CHAR(2) NOT NULL PRIMARY KEY,
+  b VARCHAR(30) NOT NULL,
+  KEY (b)
+);
+
+INSERT INTO t1 VALUES 
+('AB','MySQL AB'),
+('JA','Sun Microsystems'),
+('MS','Microsoft'),
+('IB','IBM- Inc.'),
+('GO','Google Inc.');
+
+INSERT INTO t2 VALUES
+('AB','Sweden'),
+('JA','USA'),
+('MS','United States of America'),
+('IB','North America'),
+('GO','South America');
+ 
+UPDATE t1,t2 SET t1.b=UPPER(t1.b) WHERE t1.b LIKE 'United%';
+
+SELECT * FROM t1 ORDER BY a;
+
+SELECT * FROM t2 ORDER BY a;
+
+DROP TABLE t1,t2;   
+
+--echo #
+--echo # Bug#40992 - InnoDB: Crash when engine_condition_pushdown is on
+--echo #
+
+CREATE TABLE t (
+  dummy INT PRIMARY KEY, 
+  a INT UNIQUE, 
+  b INT
+);
+
+INSERT INTO t VALUES (1,1,1),(3,3,3),(5,5,5);
+
+SELECT * FROM t WHERE a > 2 FOR UPDATE;
+
+DROP TABLE t;
+
+--echo #
+--echo # Bug#35080 - Innodb crash at mem_block_get_len line 72
+--echo #
+
+CREATE TABLE t1 (
+  t1_autoinc INT(11) NOT NULL AUTO_INCREMENT,
+  uuid VARCHAR(36) DEFAULT NULL,
+  PRIMARY KEY (t1_autoinc),
+  KEY k (uuid)
+);
+
+CREATE TABLE t2 (
+  t2_autoinc INT(11) NOT NULL AUTO_INCREMENT,
+  uuid VARCHAR(36) DEFAULT NULL,
+  date DATETIME DEFAULT NULL,
+  PRIMARY KEY (t2_autoinc),
+  KEY k (uuid)
+);
+
+CREATE VIEW v1 AS 
+  SELECT t1_autoinc, uuid
+  FROM t1
+  WHERE (ISNULL(uuid) OR (uuid like '%-%'));
+
+CREATE VIEW v2 AS 
+  SELECT t2_autoinc, uuid, date 
+  FROM t2
+  WHERE (ISNULL(uuid) OR (LENGTH(uuid) = 36));
+
+CREATE PROCEDURE delete_multi (IN uuid CHAR(36))
+  DELETE v1, v2 FROM v1 INNER JOIN v2
+  ON v1.uuid = v2.uuid
+  WHERE v1.uuid = @uuid;
+
+SET @uuid = UUID();
+
+INSERT INTO v1 (uuid) VALUES (@uuid);
+INSERT INTO v2 (uuid, date) VALUES (@uuid, '2009-09-09');
+
+CALL delete_multi(@uuid);
+
+DROP procedure delete_multi;
+DROP table t1,t2;
+DROP view v1,v2;
+
+--echo #
+--echo # Bug#41996 - multi-table delete crashes server (InnoDB table)
+--echo #
+
+CREATE TABLE t1 (
+  b BIGINT,
+  i INT, 
+  KEY (b)
+);
+
+INSERT INTO t1 VALUES (2, 2);
+
+DELETE t1 FROM t1 a, t1 WHERE a.i=t1.b;
+
+DROP TABLE t1;
+
+--echo #
+--echo # Bug#43448 - Server crashes on multi table delete with Innodb
+--echo #
+
+CREATE TABLE t1 (
+  id1 INT NOT NULL AUTO_INCREMENT PRIMARY KEY, 
+  t CHAR(12)
+);
+
+CREATE TABLE t2 (
+  id2 INT NOT NULL, 
+  t CHAR(12)
+);
+
+CREATE TABLE t3(
+  id3 INT NOT NULL, 
+  t CHAR(12), 
+  INDEX(id3)
+);
+
+delimiter |;
+
+CREATE PROCEDURE insert_data ()
+BEGIN
+  DECLARE i1 INT DEFAULT 20;
+  DECLARE i2 INT;
+  DECLARE i3 INT;
+
+  WHILE (i1 > 0) DO
+    INSERT INTO t1(t) VALUES (i1);
+    SET i2 = 2;
+    WHILE (i2 > 0) DO
+      INSERT INTO t2(id2, t) VALUES (i1, i2);
+      SET i3 = 2;
+      WHILE (i3 > 0) DO
+        INSERT INTO t3(id3, t) VALUES (i1, i2);
+        SET i3 = i3 -1;
+      END WHILE;
+      SET i2 = i2 -1;
+    END WHILE;
+    SET i1 = i1 - 1;
+  END WHILE;
+END |
+
+delimiter ;|
+
+CALL insert_data();
+
+SELECT COUNT(*) FROM t1 WHERE id1 > 10;
+SELECT COUNT(*) FROM t2 WHERE id2 > 10;
+SELECT COUNT(*) FROM t3 WHERE id3 > 10;
+
+DELETE t1, t2, t3 
+FROM t1, t2, t3 
+WHERE t1.id1 = t2.id2 AND t2.id2 = t3.id3 AND t1.id1 > 3;
+
+SELECT COUNT(*) FROM t1;
+SELECT COUNT(*) FROM t2;
+SELECT COUNT(*) FROM t3;
+
+DROP PROCEDURE insert_data;
+DROP TABLE t1, t2, t3;
+

=== modified file 'mysql-test/r/innodb_icp.result'
--- a/mysql-test/r/innodb_icp.result	2010-02-25 12:55:31 +0000
+++ b/mysql-test/r/innodb_icp.result	2010-02-26 09:19:30 +0000
@@ -51,4 +51,165 @@ c-1999=w	filler
 c-1999=w	filler-1
 c-1999=w	filler-2
 DROP TABLE t1,t2,t3;
+#
+# Bug#43360 - Server crash with a simple multi-table update
+#
+CREATE TABLE t1 (
+a CHAR(2) NOT NULL PRIMARY KEY, 
+b VARCHAR(20) NOT NULL,
+KEY (b)
+);
+CREATE TABLE t2 (
+a CHAR(2) NOT NULL PRIMARY KEY,
+b VARCHAR(30) NOT NULL,
+KEY (b)
+);
+INSERT INTO t1 VALUES 
+('AB','MySQL AB'),
+('JA','Sun Microsystems'),
+('MS','Microsoft'),
+('IB','IBM- Inc.'),
+('GO','Google Inc.');
+INSERT INTO t2 VALUES
+('AB','Sweden'),
+('JA','USA'),
+('MS','United States of America'),
+('IB','North America'),
+('GO','South America');
+UPDATE t1,t2 SET t1.b=UPPER(t1.b) WHERE t1.b LIKE 'United%';
+SELECT * FROM t1 ORDER BY a;
+a	b
+AB	MySQL AB
+GO	Google Inc.
+IB	IBM- Inc.
+JA	Sun Microsystems
+MS	Microsoft
+SELECT * FROM t2 ORDER BY a;
+a	b
+AB	Sweden
+GO	South America
+IB	North America
+JA	USA
+MS	United States of America
+DROP TABLE t1,t2;
+#
+# Bug#40992 - InnoDB: Crash when engine_condition_pushdown is on
+#
+CREATE TABLE t (
+dummy INT PRIMARY KEY, 
+a INT UNIQUE, 
+b INT
+);
+INSERT INTO t VALUES (1,1,1),(3,3,3),(5,5,5);
+SELECT * FROM t WHERE a > 2 FOR UPDATE;
+dummy	a	b
+3	3	3
+5	5	5
+DROP TABLE t;
+#
+# Bug#35080 - Innodb crash at mem_block_get_len line 72
+#
+CREATE TABLE t1 (
+t1_autoinc INT(11) NOT NULL AUTO_INCREMENT,
+uuid VARCHAR(36) DEFAULT NULL,
+PRIMARY KEY (t1_autoinc),
+KEY k (uuid)
+);
+CREATE TABLE t2 (
+t2_autoinc INT(11) NOT NULL AUTO_INCREMENT,
+uuid VARCHAR(36) DEFAULT NULL,
+date DATETIME DEFAULT NULL,
+PRIMARY KEY (t2_autoinc),
+KEY k (uuid)
+);
+CREATE VIEW v1 AS 
+SELECT t1_autoinc, uuid
+FROM t1
+WHERE (ISNULL(uuid) OR (uuid like '%-%'));
+CREATE VIEW v2 AS 
+SELECT t2_autoinc, uuid, date 
+FROM t2
+WHERE (ISNULL(uuid) OR (LENGTH(uuid) = 36));
+CREATE PROCEDURE delete_multi (IN uuid CHAR(36))
+DELETE v1, v2 FROM v1 INNER JOIN v2
+ON v1.uuid = v2.uuid
+WHERE v1.uuid = @uuid;
+SET @uuid = UUID();
+INSERT INTO v1 (uuid) VALUES (@uuid);
+INSERT INTO v2 (uuid, date) VALUES (@uuid, '2009-09-09');
+CALL delete_multi(@uuid);
+DROP procedure delete_multi;
+DROP table t1,t2;
+DROP view v1,v2;
+#
+# Bug#41996 - multi-table delete crashes server (InnoDB table)
+#
+CREATE TABLE t1 (
+b BIGINT,
+i INT, 
+KEY (b)
+);
+INSERT INTO t1 VALUES (2, 2);
+DELETE t1 FROM t1 a, t1 WHERE a.i=t1.b;
+DROP TABLE t1;
+#
+# Bug#43448 - Server crashes on multi table delete with Innodb
+#
+CREATE TABLE t1 (
+id1 INT NOT NULL AUTO_INCREMENT PRIMARY KEY, 
+t CHAR(12)
+);
+CREATE TABLE t2 (
+id2 INT NOT NULL, 
+t CHAR(12)
+);
+CREATE TABLE t3(
+id3 INT NOT NULL, 
+t CHAR(12), 
+INDEX(id3)
+);
+CREATE PROCEDURE insert_data ()
+BEGIN
+DECLARE i1 INT DEFAULT 20;
+DECLARE i2 INT;
+DECLARE i3 INT;
+WHILE (i1 > 0) DO
+INSERT INTO t1(t) VALUES (i1);
+SET i2 = 2;
+WHILE (i2 > 0) DO
+INSERT INTO t2(id2, t) VALUES (i1, i2);
+SET i3 = 2;
+WHILE (i3 > 0) DO
+INSERT INTO t3(id3, t) VALUES (i1, i2);
+SET i3 = i3 -1;
+END WHILE;
+SET i2 = i2 -1;
+END WHILE;
+SET i1 = i1 - 1;
+END WHILE;
+END |
+CALL insert_data();
+SELECT COUNT(*) FROM t1 WHERE id1 > 10;
+COUNT(*)
+10
+SELECT COUNT(*) FROM t2 WHERE id2 > 10;
+COUNT(*)
+20
+SELECT COUNT(*) FROM t3 WHERE id3 > 10;
+COUNT(*)
+40
+DELETE t1, t2, t3 
+FROM t1, t2, t3 
+WHERE t1.id1 = t2.id2 AND t2.id2 = t3.id3 AND t1.id1 > 3;
+SELECT COUNT(*) FROM t1;
+COUNT(*)
+3
+SELECT COUNT(*) FROM t2;
+COUNT(*)
+6
+SELECT COUNT(*) FROM t3;
+COUNT(*)
+12
+DROP PROCEDURE insert_data;
+DROP TABLE t1, t2, t3;
 set storage_engine= @save_storage_engine;

=== modified file 'mysql-test/r/myisam_icp.result'
--- a/mysql-test/r/myisam_icp.result	2010-02-25 12:55:31 +0000
+++ b/mysql-test/r/myisam_icp.result	2010-02-26 09:19:30 +0000
@@ -48,3 +48,164 @@ c-1997=w	filler-2
 c-1998=w	filler-2
 c-1999=w	filler-2
 DROP TABLE t1,t2,t3;
+#
+# Bug#43360 - Server crash with a simple multi-table update
+#
+CREATE TABLE t1 (
+a CHAR(2) NOT NULL PRIMARY KEY, 
+b VARCHAR(20) NOT NULL,
+KEY (b)
+);
+CREATE TABLE t2 (
+a CHAR(2) NOT NULL PRIMARY KEY,
+b VARCHAR(30) NOT NULL,
+KEY (b)
+);
+INSERT INTO t1 VALUES 
+('AB','MySQL AB'),
+('JA','Sun Microsystems'),
+('MS','Microsoft'),
+('IB','IBM- Inc.'),
+('GO','Google Inc.');
+INSERT INTO t2 VALUES
+('AB','Sweden'),
+('JA','USA'),
+('MS','United States of America'),
+('IB','North America'),
+('GO','South America');
+UPDATE t1,t2 SET t1.b=UPPER(t1.b) WHERE t1.b LIKE 'United%';
+SELECT * FROM t1 ORDER BY a;
+a	b
+AB	MySQL AB
+GO	Google Inc.
+IB	IBM- Inc.
+JA	Sun Microsystems
+MS	Microsoft
+SELECT * FROM t2 ORDER BY a;
+a	b
+AB	Sweden
+GO	South America
+IB	North America
+JA	USA
+MS	United States of America
+DROP TABLE t1,t2;
+#
+# Bug#40992 - InnoDB: Crash when engine_condition_pushdown is on
+#
+CREATE TABLE t (
+dummy INT PRIMARY KEY, 
+a INT UNIQUE, 
+b INT
+);
+INSERT INTO t VALUES (1,1,1),(3,3,3),(5,5,5);
+SELECT * FROM t WHERE a > 2 FOR UPDATE;
+dummy	a	b
+3	3	3
+5	5	5
+DROP TABLE t;
+#
+# Bug#35080 - Innodb crash at mem_block_get_len line 72
+#
+CREATE TABLE t1 (
+t1_autoinc INT(11) NOT NULL AUTO_INCREMENT,
+uuid VARCHAR(36) DEFAULT NULL,
+PRIMARY KEY (t1_autoinc),
+KEY k (uuid)
+);
+CREATE TABLE t2 (
+t2_autoinc INT(11) NOT NULL AUTO_INCREMENT,
+uuid VARCHAR(36) DEFAULT NULL,
+date DATETIME DEFAULT NULL,
+PRIMARY KEY (t2_autoinc),
+KEY k (uuid)
+);
+CREATE VIEW v1 AS 
+SELECT t1_autoinc, uuid
+FROM t1
+WHERE (ISNULL(uuid) OR (uuid like '%-%'));
+CREATE VIEW v2 AS 
+SELECT t2_autoinc, uuid, date 
+FROM t2
+WHERE (ISNULL(uuid) OR (LENGTH(uuid) = 36));
+CREATE PROCEDURE delete_multi (IN uuid CHAR(36))
+DELETE v1, v2 FROM v1 INNER JOIN v2
+ON v1.uuid = v2.uuid
+WHERE v1.uuid = @uuid;
+SET @uuid = UUID();
+INSERT INTO v1 (uuid) VALUES (@uuid);
+INSERT INTO v2 (uuid, date) VALUES (@uuid, '2009-09-09');
+CALL delete_multi(@uuid);
+DROP procedure delete_multi;
+DROP table t1,t2;
+DROP view v1,v2;
+#
+# Bug#41996 - multi-table delete crashes server (InnoDB table)
+#
+CREATE TABLE t1 (
+b BIGINT,
+i INT, 
+KEY (b)
+);
+INSERT INTO t1 VALUES (2, 2);
+DELETE t1 FROM t1 a, t1 WHERE a.i=t1.b;
+DROP TABLE t1;
+#
+# Bug#43448 - Server crashes on multi table delete with Innodb
+#
+CREATE TABLE t1 (
+id1 INT NOT NULL AUTO_INCREMENT PRIMARY KEY, 
+t CHAR(12)
+);
+CREATE TABLE t2 (
+id2 INT NOT NULL, 
+t CHAR(12)
+);
+CREATE TABLE t3(
+id3 INT NOT NULL, 
+t CHAR(12), 
+INDEX(id3)
+);
+CREATE PROCEDURE insert_data ()
+BEGIN
+DECLARE i1 INT DEFAULT 20;
+DECLARE i2 INT;
+DECLARE i3 INT;
+WHILE (i1 > 0) DO
+INSERT INTO t1(t) VALUES (i1);
+SET i2 = 2;
+WHILE (i2 > 0) DO
+INSERT INTO t2(id2, t) VALUES (i1, i2);
+SET i3 = 2;
+WHILE (i3 > 0) DO
+INSERT INTO t3(id3, t) VALUES (i1, i2);
+SET i3 = i3 -1;
+END WHILE;
+SET i2 = i2 -1;
+END WHILE;
+SET i1 = i1 - 1;
+END WHILE;
+END |
+CALL insert_data();
+SELECT COUNT(*) FROM t1 WHERE id1 > 10;
+COUNT(*)
+10
+SELECT COUNT(*) FROM t2 WHERE id2 > 10;
+COUNT(*)
+20
+SELECT COUNT(*) FROM t3 WHERE id3 > 10;
+COUNT(*)
+40
+DELETE t1, t2, t3 
+FROM t1, t2, t3 
+WHERE t1.id1 = t2.id2 AND t2.id2 = t3.id3 AND t1.id1 > 3;
+SELECT COUNT(*) FROM t1;
+COUNT(*)
+3
+SELECT COUNT(*) FROM t2;
+COUNT(*)
+6
+SELECT COUNT(*) FROM t3;
+COUNT(*)
+12
+DROP PROCEDURE insert_data;
+DROP TABLE t1, t2, t3;

=== removed file 'mysql-test/suite/optimizer_unfixed_bugs/r/bug40992.result'
--- a/mysql-test/suite/optimizer_unfixed_bugs/r/bug40992.result	2009-10-29 13:02:56 +0000
+++ b/mysql-test/suite/optimizer_unfixed_bugs/r/bug40992.result	1970-01-01 00:00:00 +0000
@@ -1,14 +0,0 @@
-#
-# Bug#40992 - InnoDB: Crash when engine_condition_pushdown is on
-#
-CREATE TABLE t (
-dummy INT PRIMARY KEY, 
-a INT UNIQUE, 
-b int
-) ENGINE=InnoDB;
-INSERT INTO t VALUES (1,1,1),(3,3,3),(5,5,5);
-SELECT * FROM t WHERE a > 2 FOR UPDATE;
-dummy	a	b
-3	3	3
-5	5	5
-DROP TABLE t;

=== removed file 'mysql-test/suite/optimizer_unfixed_bugs/r/bug41996.result'
--- a/mysql-test/suite/optimizer_unfixed_bugs/r/bug41996.result	2009-10-09 19:45:32 +0000
+++ b/mysql-test/suite/optimizer_unfixed_bugs/r/bug41996.result	1970-01-01 00:00:00 +0000
@@ -1,7 +0,0 @@
-drop table if exists `t1`;
-Warnings:
-Note	1051	Unknown table 't1'
-create table `t1` (`c` bigint, key(`c`),`a` int)engine=innodb;
-insert into `t1` values(2,2);
-delete `t1` from `t1` `a`, `t1` where `a`.`a`=`t1`.`c` ;
-drop table `t1`;

=== removed file 'mysql-test/suite/optimizer_unfixed_bugs/r/bug43360.result'
--- a/mysql-test/suite/optimizer_unfixed_bugs/r/bug43360.result	2009-10-08 19:44:58 +0000
+++ b/mysql-test/suite/optimizer_unfixed_bugs/r/bug43360.result	1970-01-01 00:00:00 +0000
@@ -1,43 +0,0 @@
-#
-# Bug#43360 - Server crash with a simple multi-table update
-#
-CREATE TABLE t1 (
-a CHAR(2) NOT NULL PRIMARY KEY, 
-b VARCHAR(20) NOT NULL,
-KEY (b)
-) ENGINE=InnoDB;
-CREATE TABLE t2 (
-a CHAR(2) NOT NULL PRIMARY KEY,
-b VARCHAR(20) NOT NULL,
-KEY (b)
-) ENGINE=InnoDB;
-INSERT INTO t1 VALUES 
-('AB','MySQLAB'),
-('JA','Sun Microsystems'),
-('MS','Microsoft'),
-('IB','IBM- Inc.'),
-('GO','Google Inc.');
-INSERT INTO t2 VALUES
-('AB','Sweden'),
-('JA','USA'),
-('MS','United States of America'),
-('IB','North America'),
-('GO','South America');
-Warnings:
-Warning	1265	Data truncated for column 'b' at row 3
-UPDATE t1,t2 SET t1.b=UPPER(t1.b) WHERE t1.b LIKE 'United%';
-SELECT * FROM t1;
-a	b
-GO	Google Inc.
-IB	IBM- Inc.
-MS	Microsoft
-AB	MySQLAB
-JA	Sun Microsystems
-SELECT * FROM t2;
-a	b
-IB	North America
-GO	South America
-AB	Sweden
-MS	United States of Ame
-JA	USA
-DROP TABLE t1,t2;

=== removed file 'mysql-test/suite/optimizer_unfixed_bugs/r/bug43448.result'
--- a/mysql-test/suite/optimizer_unfixed_bugs/r/bug43448.result	2009-11-13 14:41:07 +0000
+++ b/mysql-test/suite/optimizer_unfixed_bugs/r/bug43448.result	1970-01-01 00:00:00 +0000
@@ -1,29 +0,0 @@
-#
-# Bug#43448 - Server crashes on multi table delete with Innodb
-#
-CREATE TABLE t1 (
-id1 INT NOT NULL AUTO_INCREMENT PRIMARY KEY, 
-t CHAR(12)
-) ENGINE=InnoDB;
-CREATE TABLE t2 (
-id2 INT NOT NULL, 
-t CHAR(12)
-) ENGINE=InnoDB;
-CREATE TABLE t3(
-id3 INT NOT NULL, 
-t CHAR(12), 
-INDEX(id3)
-) ENGINE=InnoDB;
-SELECT COUNT(*) FROM t1 WHERE id1 > 90;
-COUNT(*)
-10
-SELECT COUNT(*) FROM t2 WHERE id2 > 90;
-COUNT(*)
-50
-SELECT COUNT(*) FROM t3 WHERE id3 > 90;
-COUNT(*)
-500
-DELETE t1, t2, t3 
-FROM t1, t2, t3 
-WHERE t1.id1 = t2.id2 AND t2.id2 = t3.id3 AND t1.id1 > 5;
-DROP TABLE t1, t2, t3;

=== removed file 'mysql-test/suite/optimizer_unfixed_bugs/t/bug40992.test'
--- a/mysql-test/suite/optimizer_unfixed_bugs/t/bug40992.test	2009-10-29 13:02:56 +0000
+++ b/mysql-test/suite/optimizer_unfixed_bugs/t/bug40992.test	1970-01-01 00:00:00 +0000
@@ -1,21 +0,0 @@
---echo #
---echo # Bug#40992 - InnoDB: Crash when engine_condition_pushdown is on
---echo #
-
---source include/have_debug.inc
---source include/have_innodb.inc
-
-# Crash requires that we enable Index Condition Pushdown in InnoDB
-set session debug="+d,optimizer_innodb_icp";
-
-CREATE TABLE t (
-  dummy INT PRIMARY KEY, 
-  a INT UNIQUE, 
-  b int
-) ENGINE=InnoDB;
-
-INSERT INTO t VALUES (1,1,1),(3,3,3),(5,5,5);
-
-SELECT * FROM t WHERE a > 2 FOR UPDATE;
-
-DROP TABLE t;

=== removed file 'mysql-test/suite/optimizer_unfixed_bugs/t/bug41996.test'
--- a/mysql-test/suite/optimizer_unfixed_bugs/t/bug41996.test	2009-10-09 19:45:32 +0000
+++ b/mysql-test/suite/optimizer_unfixed_bugs/t/bug41996.test	1970-01-01 00:00:00 +0000
@@ -1,14 +0,0 @@
-# Test for BUG#41996 "multi-table delete crashes server (InnoDB
-# table)"
-
---source include/have_debug.inc
---source include/have_innodb.inc
-
-# crash requires this
-set session debug="+d,optimizer_innodb_icp";
-
-drop table if exists `t1`;
-create table `t1` (`c` bigint, key(`c`),`a` int)engine=innodb;
-insert into `t1` values(2,2);
-delete `t1` from `t1` `a`, `t1` where `a`.`a`=`t1`.`c` ;
-drop table `t1`;

=== removed file 'mysql-test/suite/optimizer_unfixed_bugs/t/bug43360.test'
--- a/mysql-test/suite/optimizer_unfixed_bugs/t/bug43360.test	2009-10-10 12:33:56 +0000
+++ b/mysql-test/suite/optimizer_unfixed_bugs/t/bug43360.test	1970-01-01 00:00:00 +0000
@@ -1,44 +0,0 @@
-
---echo #
---echo # Bug#43360 - Server crash with a simple multi-table update
---echo #
-
---source include/have_debug.inc
---source include/have_innodb.inc
-
-# crash requires this
-set session debug="+d,optimizer_innodb_icp";
-
-CREATE TABLE t1 (
-  a CHAR(2) NOT NULL PRIMARY KEY, 
-  b VARCHAR(20) NOT NULL,
-  KEY (b)
-) ENGINE=InnoDB;
-
-CREATE TABLE t2 (
-  a CHAR(2) NOT NULL PRIMARY KEY,
-  b VARCHAR(20) NOT NULL,
-  KEY (b)
-) ENGINE=InnoDB;
-
-INSERT INTO t1 VALUES 
-('AB','MySQLAB'),
-('JA','Sun Microsystems'),
-('MS','Microsoft'),
-('IB','IBM- Inc.'),
-('GO','Google Inc.');
-
-INSERT INTO t2 VALUES
-('AB','Sweden'),
-('JA','USA'),
-('MS','United States of America'),
-('IB','North America'),
-('GO','South America');
- 
-UPDATE t1,t2 SET t1.b=UPPER(t1.b) WHERE t1.b LIKE 'United%';
-
-SELECT * FROM t1;
-
-SELECT * FROM t2;
-
-DROP TABLE t1,t2;   

=== removed file 'mysql-test/suite/optimizer_unfixed_bugs/t/bug43448.test'
--- a/mysql-test/suite/optimizer_unfixed_bugs/t/bug43448.test	2009-11-13 14:41:07 +0000
+++ b/mysql-test/suite/optimizer_unfixed_bugs/t/bug43448.test	1970-01-01 00:00:00 +0000
@@ -1,58 +0,0 @@
---echo #
---echo # Bug#43448 - Server crashes on multi table delete with Innodb
---echo #
-
---source include/have_debug.inc
---source include/have_innodb.inc
-
-# crash requires ICP support in InnoDB
-set session debug="+d,optimizer_innodb_icp";
-
-CREATE TABLE t1 (
-  id1 INT NOT NULL AUTO_INCREMENT PRIMARY KEY, 
-  t CHAR(12)
-) ENGINE=InnoDB;
-
-CREATE TABLE t2 (
-  id2 INT NOT NULL, 
-  t CHAR(12)
-) ENGINE=InnoDB;
-
-CREATE TABLE t3(
-  id3 INT NOT NULL, 
-  t CHAR(12), 
-  INDEX(id3)
-) ENGINE=InnoDB;
-
-disable_query_log;
-
-let $1 = 100;
-while ($1)
-{
-  let $2 = 5;
-  eval INSERT INTO t1(t) VALUES ('$1');
-  while ($2)
-  {
-    eval INSERT INTO t2(id2,t) VALUES ($1,'$2');
-    let $3 = 10;
-    while ($3)
-    {
-      eval INSERT INTO t3(id3,t) VALUES ($1,'$2');
-      dec $3;
-    }
-    dec $2;
-  }
-  dec $1;
-}
-
-enable_query_log;
-
-SELECT COUNT(*) FROM t1 WHERE id1 > 90;
-SELECT COUNT(*) FROM t2 WHERE id2 > 90;
-SELECT COUNT(*) FROM t3 WHERE id3 > 90;
-
-DELETE t1, t2, t3 
-FROM t1, t2, t3 
-WHERE t1.id1 = t2.id2 AND t2.id2 = t3.id3 AND t1.id1 > 5;
-
-DROP TABLE t1, t2, t3;


Attachment: [text/bzr-bundle] bzr/olav@sun.com-20100226091930-qxvakxmcp6463t5w.bundle
Thread
bzr push into mysql-6.0-codebase-bugfixing branch (olav:2968 to 2970) Olav Sandstaa26 Feb