mariadb/mysql-test/suite
unknown 42f8d2f249 Bug#56226 Table map set to 0 after altering MyISAM table
After ALTER TABLE which changed only table's metadata, row-based
binlog sometimes got corrupted since the tablemap was unexpectedly
set to 0 for subsequent updates to the same table.

ALTER TABLE which changed only table's metadata always reset
table_map_id for the table share to 0. Despite the fact that
0 is a valid value for table_map_id, this step caused problems
as it could have created situation in which we had more than
one table share with table_map_id equal 0. If more than one
table with table_map_id are 0 were updated in the same statement,
updates to these different tables were written into the same
rows event. This caused slave server to crash.

This bug happens only on 5.1. It doesn't affect 5.5+.

This patch solves this problem by ensuring that ALTER TABLE
statements which change metadata only never reset table_map_id
to 0. To do this it changes reopen_table() to correctly use
refreshed table_map_id value instead of using the old one/
resetting it.


mysql-test/suite/rpl/r/rpl_alter.result:
  Add test for BUG#56226
mysql-test/suite/rpl/t/rpl_alter.test:
  Add test for BUG#56226
2010-10-11 11:08:49 +08:00
..
binlog BUG#55961 Savepoint Identifier should be enclosed with backticks 2010-09-02 14:05:06 +01:00
bugs Bug #49741 test files contain explicit references to bin/relay-log positions 2010-05-24 21:54:08 +08:00
engines Bug #49741 test files contain explicit references to bin/relay-log positions 2010-05-24 21:54:08 +08:00
federated Fix for bug#32426: "FEDERATED query returns corrupt results 2010-03-05 14:51:37 +04:00
funcs_1 merge from 5.1 2010-09-29 12:56:10 +02:00
funcs_2 merge 5.0-> 5.1 2009-04-24 13:00:17 -04:00
ibmdb2i Bug#49329 example (and other) engines use wrong collation for open tables hash 2009-12-11 12:31:16 +05:30
im
innodb merged mysql-5.1 into mysql-5.1-bugteam 2010-10-05 11:11:56 +03:00
innodb_plugin merged mysql-5.1 into mysql-5.1-bugteam 2010-10-05 11:11:56 +03:00
jp Bug #45159 : some tests in suite "jp" fail in embedded server (use LOAD DATA) 2009-09-11 15:52:08 +03:00
large_tests
manual Bug #49741 test files contain explicit references to bin/relay-log positions 2010-05-24 21:54:08 +08:00
ndb merged 2010-10-05 11:47:03 +03:00
ndb_team Bug #49741 test files contain explicit references to bin/relay-log positions 2010-05-24 21:54:08 +08:00
parts Bug#53806: Wrong estimates for range query in partitioned MyISAM table 2010-08-27 10:43:51 +02:00
rpl Bug#56226 Table map set to 0 after altering MyISAM table 2010-10-11 11:08:49 +08:00
rpl_ndb Postfix BUG#49741 2010-05-25 11:39:45 +08:00
stress
sys_vars test fixes after 56753 2010-09-21 11:16:20 +02:00