3738 Mattias Jonsson 2011-03-09 [merge]
merge of bug#11766232 (bug#60039).
modified:
mysql-test/r/partition_error.result
mysql-test/t/partition_error.test
sql/sql_partition_admin.cc
3737 Andrei Elkin 2011-03-08
Bug#11765758 bug#58754 RPL_CORRUPTION FAILED on mysql-trunk
There are two outstanding issues: a crash and stopping slave with an unexpected error.
The current patch is hunting over the crash. Here is the first step to sort out
whether `+d' dbug instruction that leads to the error-log relates to the crash.
Notice, no real changes neither to the sources not the tests are done.
The idea is just to watch PB2 on the win 64.
@ mysql-test/suite/rpl/r/rpl_corruption.result
results are updated.
@ mysql-test/suite/rpl/t/rpl_corruption.test
changed dbug control to use the abs not incremental syntax in order to avoid
cluttering the error log with extra info.
todo: restore to the original once relateness of the syntax to the issue got sorted out.
modified:
mysql-test/suite/rpl/r/rpl_corruption.result
mysql-test/suite/rpl/t/rpl_corruption.test
=== modified file 'mysql-test/r/partition_error.result'
--- a/mysql-test/r/partition_error.result 2011-03-01 14:47:01 +0000
+++ b/mysql-test/r/partition_error.result 2011-03-09 14:03:46 +0000
@@ -1,5 +1,15 @@
drop table if exists t1, t2;
#
+# Bug#60039: crash when exchanging a partition on
+# nonpartitioned table with a view
+#
+CREATE TABLE t1 (a int);
+CREATE OR REPLACE VIEW v1 AS SELECT * FROM t1;
+ALTER TABLE t1 EXCHANGE PARTITION p0 WITH TABLE v1;
+ERROR 42000: Can't open table
+DROP VIEW v1;
+DROP TABLE t1;
+#
# Bug#57924: crash when creating partitioned table with
# multiple columns in the partition key
#
=== modified file 'mysql-test/t/partition_error.test'
--- a/mysql-test/t/partition_error.test 2011-03-01 14:47:01 +0000
+++ b/mysql-test/t/partition_error.test 2011-03-09 14:03:46 +0000
@@ -11,6 +11,17 @@ drop table if exists t1, t2;
let $MYSQLD_DATADIR= `SELECT @@datadir`;
--echo #
+--echo # Bug#60039: crash when exchanging a partition on
+--echo # nonpartitioned table with a view
+--echo #
+CREATE TABLE t1 (a int);
+CREATE OR REPLACE VIEW v1 AS SELECT * FROM t1;
+--error ER_CHECK_NO_SUCH_TABLE
+ALTER TABLE t1 EXCHANGE PARTITION p0 WITH TABLE v1;
+DROP VIEW v1;
+DROP TABLE t1;
+
+--echo #
--echo # Bug#57924: crash when creating partitioned table with
--echo # multiple columns in the partition key
--echo #
=== modified file 'sql/sql_partition_admin.cc'
--- a/sql/sql_partition_admin.cc 2010-12-03 10:05:56 +0000
+++ b/sql/sql_partition_admin.cc 2011-02-10 09:49:47 +0000
@@ -527,11 +527,12 @@ bool Sql_cmd_alter_table_exchange_partit
part_table= table_list->table;
swap_table= swap_table_list->table;
- table_hton= swap_table->file->ht;
if (check_exchange_partition(swap_table, part_table))
DBUG_RETURN(TRUE);
+ table_hton= swap_table->file->ht;
+
thd_proc_info(thd, "verifying table");
/* Will append the partition name later in part_info->get_part_elem() */
No bundle (reason: useless for push emails).
| Thread |
|---|
| • bzr push into mysql-trunk branch (mattias.jonsson:3737 to 3738)Bug#60039 Bug#11766232 | Mattias Jonsson | 9 Mar |