| 1 |
call mtr.add_suppression("InnoDB: Warning: Index.*"); |
| 2 |
SET @saved_dbug = @@SESSION.debug_dbug; |
| 3 |
set DEBUG_DBUG='+d,ib_ha_innodb_stat_not_initialized'; |
| 4 |
create table t1(a int not null primary key, b int, c int, key(b), key(c)) engine=innodb; |
| 5 |
create procedure innodb_insert_proc (repeat_count int) |
| 6 |
begin |
| 7 |
declare current_num int; |
| 8 |
set current_num = 0; |
| 9 |
while current_num < repeat_count do |
| 10 |
insert into t1 values(current_num, current_num, current_num); |
| 11 |
set current_num = current_num + 1; |
| 12 |
end while; |
| 13 |
end// |
| 14 |
commit; |
| 15 |
set autocommit=0; |
| 16 |
call innodb_insert_proc(10000); |
| 17 |
commit; |
| 18 |
set autocommit=1; |
| 19 |
select count(1) from t1; |
| 20 |
count(1) |
| 21 |
10000 |
| 22 |
select count(1) from t1 where a between 5 and 100; |
| 23 |
count(1) |
| 24 |
96 |
| 25 |
select count(1) from t1 where b between 5 and 256; |
| 26 |
count(1) |
| 27 |
252 |
| 28 |
select count(1) from t1 where c between 7 and 787; |
| 29 |
count(1) |
| 30 |
781 |
| 31 |
drop procedure innodb_insert_proc; |
| 32 |
drop table t1; |
| 33 |
SET debug_dbug= @saved_dbug; |