mariadb/mysql-test/suite/innodb/r/innodb_bug14676111.result
Yasufumi Kinoshita 5a7553f36a Bug #14676111 WRONG PAGE_LEVEL WRITTEN FOR UPPER THAN FATHER PAGE AT BTR_LIFT_PAGE_UP()
btr_lift_page_up() writes wrong page number (different by -1) for upper than father page.
But in almost all of the cases, the father page should be root page, no upper
pages. It is very rare path.

In addition the leaf page should not be lifted unless the father page is root.
Because the branch pages should not become the leaf pages.

rb://1336 approved by Marko Makela.
2012-11-12 22:31:30 +09:00

53 lines
1.7 KiB
Text

drop table if exists t1;
CREATE TABLE t1 (a int not null primary key) engine=InnoDB;
set global innodb_limit_optimistic_insert_debug = 2;
insert into t1 values (1);
insert into t1 values (5);
insert into t1 values (4);
insert into t1 values (3);
insert into t1 values (2);
analyze table t1;
Table Op Msg_type Msg_text
test.t1 analyze status OK
select DATA_LENGTH / 16384 from information_schema.TABLES where TABLE_SCHEMA = 'test' and TABLE_NAME = 't1';
DATA_LENGTH / 16384
10.0000
delete from t1 where a=4;
analyze table t1;
Table Op Msg_type Msg_text
test.t1 analyze status OK
select DATA_LENGTH / 16384 from information_schema.TABLES where TABLE_SCHEMA = 'test' and TABLE_NAME = 't1';
DATA_LENGTH / 16384
8.0000
delete from t1 where a=5;
analyze table t1;
Table Op Msg_type Msg_text
test.t1 analyze status OK
select DATA_LENGTH / 16384 from information_schema.TABLES where TABLE_SCHEMA = 'test' and TABLE_NAME = 't1';
DATA_LENGTH / 16384
5.0000
set global innodb_limit_optimistic_insert_debug = 10000;
delete from t1 where a=2;
analyze table t1;
Table Op Msg_type Msg_text
test.t1 analyze status OK
select DATA_LENGTH / 16384 from information_schema.TABLES where TABLE_SCHEMA = 'test' and TABLE_NAME = 't1';
DATA_LENGTH / 16384
3.0000
insert into t1 values (2);
delete from t1 where a=2;
analyze table t1;
Table Op Msg_type Msg_text
test.t1 analyze status OK
select DATA_LENGTH / 16384 from information_schema.TABLES where TABLE_SCHEMA = 'test' and TABLE_NAME = 't1';
DATA_LENGTH / 16384
2.0000
insert into t1 values (2);
delete from t1 where a=2;
analyze table t1;
Table Op Msg_type Msg_text
test.t1 analyze status OK
select DATA_LENGTH / 16384 from information_schema.TABLES where TABLE_SCHEMA = 'test' and TABLE_NAME = 't1';
DATA_LENGTH / 16384
1.0000
drop table t1;