List:Commits« Previous MessageNext Message »
From:marko.makela Date:February 27 2013 6:10pm
Subject:bzr push into mysql-5.6 branch (marko.makela:4849)
View as plain text  
 4849 Marko Mäkelä	2013-02-27 [merge]
      Merge mysql-5.6 to local copy.

    modified:
      storage/innobase/buf/buf0buddy.cc
      storage/innobase/buf/buf0buf.cc
      storage/innobase/buf/buf0flu.cc
      storage/innobase/buf/buf0lru.cc
      storage/innobase/handler/i_s.cc
      storage/innobase/include/buf0buf.h
      storage/innobase/include/buf0buf.ic
      storage/innobase/include/univ.i
=== renamed file 'mysql-test/suite/innodb/include/innodb_fectch_records.inc' => 'mysql-test/suite/innodb/include/innodb_fetch_records.inc'
=== modified file 'mysql-test/suite/innodb/include/innodb_stats_comp_index.inc'
--- a/mysql-test/suite/innodb/include/innodb_stats_comp_index.inc	revid:inaam.rana@strippedjihd801n
+++ b/mysql-test/suite/innodb/include/innodb_stats_comp_index.inc	revid:marko.makela@stripped80040-o8noq4nndw2kkx0o
@@ -1,12 +1,12 @@
 --echo ===============
---echo Chekc the stats of the table
+--echo Check the stats of the table
 --echo Check the size of the ibd file
 --echo ===============
 
 -- echo # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
@@ -16,12 +16,12 @@ perl;
  my $dir = $ENV{'MYSQLD_DATADIR'}."test";
  my $size;
  opendir(DIR, $dir) or die $!;
- while (my $file = readdir(DIR)) 
+ while (my $file = readdir(DIR))
  {
- 
+
    next unless ($file =~ m/\.ibd$/);
    $size = -s "$dir/$file";
-   print "The size of the tab5.ibd file: $size \n"; 
+   print "The size of the tab5.ibd file: $size\n";
  }
  close(DIR);
  exit(0)

=== modified file 'mysql-test/suite/innodb/r/innodb_cmp_per_index.result'
--- a/mysql-test/suite/innodb/r/innodb_cmp_per_index.result	revid:inaam.rana@oracle.com-20130227172310-2x0i8gwqjihd801n
+++ b/mysql-test/suite/innodb/r/innodb_cmp_per_index.result	revid:marko.makela@stripped
@@ -62,8 +62,8 @@ uncompress_ops	0
 database_name	test
 table_name	t
 index_name	PRIMARY
-compress_ops	47
-compress_ops_ok	47
+compress_ops	58
+compress_ops_ok	58
 uncompress_ops	0
 database_name	unknown
 table_name	unknown

=== modified file 'mysql-test/suite/innodb/r/innodb_wl6347_comp_indx_stat.result'
--- a/mysql-test/suite/innodb/r/innodb_wl6347_comp_indx_stat.result	revid:inaam.rana@stripped0227172310-2x0i8gwqjihd801n
+++ b/mysql-test/suite/innodb/r/innodb_wl6347_comp_indx_stat.result	revid:marko.makela@oracle.com-20130227180040-o8noq4nndw2kkx0o
@@ -1,10 +1,4 @@
-USE test;
-DROP TABLE IF EXISTS tab5;
-Warnings:
-Level	Note
-Code	1051
-Message	Unknown table 'test.tab5'
-# set the flags 
+# set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -30,21 +24,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for deterministic reasons simple data should be inserted.
+# insert some 100 records
 ===============
 Load the data
 ===============
@@ -261,19 +255,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 2097152 
+The size of the tab5.ibd file: 2097152
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -287,19 +281,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 2097152 
+The size of the tab5.ibd file: 2097152
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -314,23 +308,23 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 2097152 
+The size of the tab5.ibd file: 2097152
 # Restarting server
 # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# set the flags 
+# set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_compression_level=0;
@@ -345,7 +339,7 @@ LIMIT 1;
 col_7	gggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggg
 col_8	hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
 col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
-# check the stats of the table 
+# check the stats of the table
 # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=1;
@@ -361,12 +355,11 @@ AND uncompress_ops BETWEEN @uncomp_val A
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-#cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
-# create a table with page size=2K 
+# create a table with page size=2K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -387,21 +380,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -618,19 +611,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 2097152 
+The size of the tab5.ibd file: 2097152
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -644,19 +637,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 2097152 
+The size of the tab5.ibd file: 2097152
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -671,23 +664,23 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 2097152 
+The size of the tab5.ibd file: 2097152
 # Restarting server
 # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# set the flags 
+# set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_compression_level=0;
@@ -702,7 +695,7 @@ LIMIT 1;
 col_7	gggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggg
 col_8	hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
 col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
-# check the stats of the table 
+# check the stats of the table
 # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=2;
@@ -718,12 +711,11 @@ AND uncompress_ops BETWEEN @uncomp_val A
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-#cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
-# create a table with page size=4K 
+# create a table with page size=4K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -744,21 +736,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -975,19 +967,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 159744 
+The size of the tab5.ibd file: 159744
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -1001,19 +993,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 159744 
+The size of the tab5.ibd file: 159744
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -1028,25 +1020,24 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 159744 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 159744
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
-# create a table with page size=8K 
+# create a table with page size=8K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -1067,21 +1058,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 122880 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 122880
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -1298,19 +1289,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 212992 
+The size of the tab5.ibd file: 212992
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -1324,19 +1315,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 212992 
+The size of the tab5.ibd file: 212992
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -1351,25 +1342,24 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 212992 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 212992
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
-# create a table with page size=16K 
+# create a table with page size=16K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -1390,21 +1380,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 245760 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 245760
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -1621,19 +1611,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
+The size of the tab5.ibd file: 327680
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -1647,19 +1637,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
+The size of the tab5.ibd file: 327680
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -1674,35 +1664,28 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
-#cleanup
-DROP TABLE IF EXISTS tab5;
-USE test;
-DROP TABLE IF EXISTS tab5;
-Warnings:
-Level	Note
-Code	1051
-Message	Unknown table 'test.tab5'
+The size of the tab5.ibd file: 327680
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
-# set the flags 
+# set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_compression_level=9;
-# create a table with page size=1K 
+# create a table with page size=1K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -1724,21 +1707,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # The size of the file with 0 compress = 65536
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -1956,19 +1939,19 @@ commit;
 # The size of the file with 0 compress = 2097152
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -1982,19 +1965,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -2009,23 +1992,23 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # Restarting server
 # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# set the flags 
+# set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_compression_level=9;
@@ -2040,7 +2023,7 @@ LIMIT 1;
 col_7	gggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggg
 col_8	hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
 col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
-# check the stats of the table 
+# check the stats of the table
 # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=1;
@@ -2056,12 +2039,11 @@ AND uncompress_ops BETWEEN @uncomp_val A
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-#cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# create a table with page size=2K 
+# create a table with page size=2K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -2083,21 +2065,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # The size of the file with 0 compress = 65536
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -2315,19 +2297,19 @@ commit;
 # The size of the file with 0 compress = 2097152
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -2341,19 +2323,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -2368,23 +2350,23 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # Restarting server
 # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# set the flags 
+# set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_compression_level=9;
@@ -2399,7 +2381,7 @@ LIMIT 1;
 col_7	gggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggg
 col_8	hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
 col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
-# check the stats of the table 
+# check the stats of the table
 # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=1;
@@ -2415,12 +2397,11 @@ AND uncompress_ops BETWEEN @uncomp_val A
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-#cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# create a table with page size=4K 
+# create a table with page size=4K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -2442,21 +2423,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # The size of the file with 0 compress = 65536
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -2674,19 +2655,19 @@ commit;
 # The size of the file with 0 compress = 159744
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
+The size of the tab5.ibd file: 81920
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -2700,19 +2681,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
+The size of the tab5.ibd file: 81920
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -2727,25 +2708,24 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 81920
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# create a table with page size=8K 
+# create a table with page size=8K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -2767,21 +2747,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # The size of the file with 0 compress = 122880
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 122880 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 122880
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -2998,19 +2978,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
+The size of the tab5.ibd file: 163840
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -3022,22 +3002,22 @@ col_7	gggggggggggggggggggggggggggggggggg
 col_8	hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
 col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
-# The size of the file with 0 compress = 212992 
+# The size of the file with 0 compress = 212992
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
+The size of the tab5.ibd file: 163840
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -3052,25 +3032,24 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 163840
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# create a table with page size=16K 
+# create a table with page size=16K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -3092,21 +3071,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # The size of the file with 0 compress = 245760
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 245760 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 245760
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -3323,19 +3302,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
+The size of the tab5.ibd file: 327680
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -3350,19 +3329,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # The size of the file with 0 compress = 344064
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
+The size of the tab5.ibd file: 327680
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -3377,26 +3356,25 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 327680
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 SET GLOBAL innodb_compression_level=default;
-# create a table with page size=1K 
+# create a table with page size=1K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -3418,21 +3396,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # The size of the file with 0 compress = 65536
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -3650,19 +3628,19 @@ commit;
 # The size of the file with 0 compress = 65536
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -3676,19 +3654,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -3703,26 +3681,25 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 65536
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 SET GLOBAL innodb_compression_level=default;
-# create a table with page size=4K 
+# create a table with page size=4K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -3744,21 +3721,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # The size of the file with 0 compress = 65536
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -3976,19 +3953,19 @@ commit;
 # The size of the file with 0 compress = 86016
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
+The size of the tab5.ibd file: 81920
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -4002,26 +3979,25 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 81920
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 SET GLOBAL innodb_compression_level=default;
-# create a table with page size=8K 
+# create a table with page size=8K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -4043,21 +4019,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # The size of the file with 0 compress = 122880
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 122880 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 122880
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -4275,19 +4251,19 @@ commit;
 # The size of the file with 0 compress = 172032
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
+The size of the tab5.ibd file: 163840
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -4301,26 +4277,25 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 163840
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 SET GLOBAL innodb_compression_level=default;
-# create a table with page size=16K 
+# create a table with page size=16K
 # create indexes on each column.(total 9 indexes)
 ===============
 create table & Index
@@ -4342,21 +4317,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # The size of the file with 0 compress = 245760
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 245760 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 245760
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -4574,19 +4549,19 @@ commit;
 # The size of the file with 0 compress = 344064
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
+The size of the tab5.ibd file: 327680
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -4600,31 +4575,24 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
-#cleanup
-DROP TABLE IF EXISTS tab5;
-USE test;
-DROP TABLE IF EXISTS tab5;
-Warnings:
-Level	Note
-Code	1051
-Message	Unknown table 'test.tab5'
+The size of the tab5.ibd file: 327680
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# set the flags 
+# set the flags
 SET GLOBAL innodb_compression_failure_threshold_pct=0;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 # check the flags
@@ -4659,21 +4627,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -4890,19 +4858,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -4916,19 +4884,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -4943,23 +4911,23 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # Restarting server
 # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# set the flags 
+# set the flags
 SET GLOBAL innodb_compression_failure_threshold_pct=0;
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
@@ -4974,7 +4942,7 @@ LIMIT 1;
 col_7	gggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggg
 col_8	hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
 col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
-# check the stats of the table 
+# check the stats of the table
 # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=1;
@@ -4990,8 +4958,7 @@ AND uncompress_ops BETWEEN @uncomp_val A
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-#cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -5016,21 +4983,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -5247,19 +5214,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -5273,19 +5240,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -5300,21 +5267,20 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 65536
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -5339,21 +5305,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -5570,19 +5536,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
+The size of the tab5.ibd file: 81920
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -5596,19 +5562,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
+The size of the tab5.ibd file: 81920
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -5623,21 +5589,20 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 81920
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -5662,21 +5627,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 122880 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 122880
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -5893,19 +5858,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
+The size of the tab5.ibd file: 163840
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -5919,19 +5884,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
+The size of the tab5.ibd file: 163840
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -5946,21 +5911,20 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 163840
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -5985,21 +5949,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 245760 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 245760
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -6216,19 +6180,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
+The size of the tab5.ibd file: 327680
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -6242,19 +6206,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
+The size of the tab5.ibd file: 327680
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -6269,31 +6233,24 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 327680
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-USE test;
-DROP TABLE IF EXISTS tab5;
-Warnings:
-Level	Note
-Code	1051
-Message	Unknown table 'test.tab5'
-# set the flags 
+# set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -6331,21 +6288,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -6562,19 +6519,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -6588,19 +6545,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -6615,23 +6572,23 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # Restarting server
 # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
-# set the flags 
+# set the flags
 SET GLOBAL innodb_compression_failure_threshold_pct=10;
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
@@ -6647,7 +6604,7 @@ LIMIT 1;
 col_7	gggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggg
 col_8	hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
 col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
-# check the stats of the table 
+# check the stats of the table
 # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=1;
@@ -6663,8 +6620,7 @@ AND uncompress_ops BETWEEN @uncomp_val A
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-#cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -6690,21 +6646,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -6921,19 +6877,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -6947,19 +6903,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
+The size of the tab5.ibd file: 65536
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -6974,21 +6930,20 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=2;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 65536
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -7013,21 +6968,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 65536 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 65536
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -7244,19 +7199,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
+The size of the tab5.ibd file: 81920
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -7270,19 +7225,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
+The size of the tab5.ibd file: 81920
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -7297,21 +7252,20 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 86016 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 81920
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -7337,21 +7291,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 122880 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 122880
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -7568,19 +7522,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
+The size of the tab5.ibd file: 163840
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -7594,19 +7548,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
+The size of the tab5.ibd file: 163840
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -7621,21 +7575,20 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 172032 
-#cleanup
-DROP TABLE IF EXISTS tab5;
+The size of the tab5.ibd file: 163840
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -7660,21 +7613,21 @@ CREATE INDEX  idx1 ON tab5(col_1(10));
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 245760 
-# for determintic resons simple data should be inserted. 
-#insert some 100 records 
+The size of the tab5.ibd file: 245760
+# for determintic resons simple data should be inserted.
+#insert some 100 records
 ===============
 Load the data
 ===============
@@ -7891,19 +7844,19 @@ commit;
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
+The size of the tab5.ibd file: 327680
 # fetch the compressed page and check the stats
 ===============
 Fetch Records
@@ -7917,19 +7870,19 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
+The size of the tab5.ibd file: 327680
 # fetch the compressed same page once again and check the stats
 # the stat figures should be same as above query
 ===============
@@ -7944,22 +7897,20 @@ col_9	iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
 # check the stats of the table & size of the table
 SET @inl_val=1;
 ===============
-Chekc the stats of the table
+Check the stats of the table
 Check the size of the ibd file
 ===============
 # testcase : pass = 1 fail = 0
 SELECT count(*) > 0 as "compress_stat"
 FROM information_schema.innodb_cmp_per_index
-WHERE 
+WHERE
 compress_ops_ok BETWEEN @inl_val AND 1000
 AND compress_ops BETWEEN @inl_val AND 1000
 AND table_name='tab5' AND database_name='test'
 AND index_name like 'idx%' ;
 compress_stat	1
-The size of the tab5.ibd file: 344064 
-#cleanup
-DROP TABLE IF EXISTS tab5;
-USE test;
+The size of the tab5.ibd file: 327680
+DROP TABLE tab5;
 #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
@@ -7970,10 +7921,9 @@ SET GLOBAL innodb_compression_failure_th
 #create a table page size=1K
 CREATE TABLE tab5(col_1 TINYBLOB, col_2 TINYTEXT,col_3 BLOB,
 col_4 TEXT,col_5 MEDIUMBLOB,col_6 MEDIUMTEXT,
-col_7 LONGBLOB,col_8 LONGTEXT,col_9 VARCHAR(255)) 
+col_7 LONGBLOB,col_8 LONGTEXT,col_9 VARCHAR(255))
 ENGINE=INNODB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1;
-#create index
-CREATE INDEX  idx1 ON tab5(col_1(10));
+CREATE INDEX idx1 ON tab5(col_1(10));
 #check the stats of the table
 SELECT database_name,table_name,index_name,compress_ops,compress_ops_ok
 FROM information_schema.innodb_cmp_per_index
@@ -7994,11 +7944,9 @@ USE sb;
 #create a table page size=1K (testcase-1)
 CREATE TABLE tab5(col_1 TINYBLOB, col_2 TINYTEXT,col_3 BLOB,
 col_4 TEXT,col_5 MEDIUMBLOB,col_6 MEDIUMTEXT,
-col_7 LONGBLOB,col_8 LONGTEXT,col_9 VARCHAR(255)) 
+col_7 LONGBLOB,col_8 LONGTEXT,col_9 VARCHAR(255))
 ENGINE=INNODB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1;
-#create index
-CREATE INDEX  idx1 ON tab5(col_1(10));
-#check the stats of the table
+CREATE INDEX idx1 ON tab5(col_1(10));
 SELECT database_name,table_name,index_name,compress_ops,compress_ops_ok
 FROM information_schema.innodb_cmp_per_index
 WHERE database_name='sb' and table_name='tab5'
@@ -8013,13 +7961,9 @@ table_name	tab5
 index_name	idx1
 compress_ops	1
 compress_ops_ok	1
-#cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5, test.tab5;
 DROP DATABASE sb;
-USE test;
-#cleanup
-DROP TABLE IF EXISTS tab5;
-# reset back the flags 
+# reset the flags
 SET GLOBAL innodb_file_per_table=default;
 SET GLOBAL innodb_file_format=default;
 SET GLOBAL innodb_cmp_per_index_enabled=default;

=== modified file 'mysql-test/suite/innodb/t/innodb_wl6347_comp_indx_stat.test'
--- a/mysql-test/suite/innodb/t/innodb_wl6347_comp_indx_stat.test	revid:inaam.rana@oracle.com-20130227172310-2x0i8gwqjihd801n
+++ b/mysql-test/suite/innodb/t/innodb_wl6347_comp_indx_stat.test	revid:marko.makela@stripped
@@ -17,11 +17,7 @@
 
 let MYSQLD_DATADIR=`SELECT @@datadir`;
 
-
-USE test;
-DROP TABLE IF EXISTS tab5;
-
---echo # set the flags 
+--echo # set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -41,8 +37,8 @@ let $block_size=1;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for deterministic reasons simple data should be inserted.
+--echo # insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -51,7 +47,7 @@ SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -59,7 +55,7 @@ SET @inl_val=2;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -71,24 +67,22 @@ SET @inl_val=2;
 --echo # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # set the flags 
+--echo # set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_compression_level=0;
 
-
 --echo # fetch the compressed page and check the stats
 --echo # The stats figure may be different/same for each restart.
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
---echo # check the stats of the table 
+--echo # check the stats of the table
 -- echo # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=1;
 --source suite/innodb/include/innodb_stats_restart.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=0
@@ -99,7 +93,7 @@ DROP TABLE IF EXISTS tab5;
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
 
---echo # create a table with page size=2K 
+--echo # create a table with page size=2K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=2;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -108,8 +102,8 @@ let $block_size=2;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -118,7 +112,7 @@ SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -126,7 +120,7 @@ SET @inl_val=2;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -138,24 +132,22 @@ SET @inl_val=2;
 --echo # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # set the flags 
+--echo # set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_compression_level=0;
 
 --echo # fetch the compressed page and check the stats
 --echo # The stats figure may be different/same for each restart.
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
---echo # check the stats of the table 
+--echo # check the stats of the table
 -- echo # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=2;
 --source suite/innodb/include/innodb_stats_restart.inc
 
-
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=0
@@ -166,7 +158,7 @@ DROP TABLE IF EXISTS tab5;
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
 
---echo # create a table with page size=4K 
+--echo # create a table with page size=4K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=4;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -175,8 +167,8 @@ let $block_size=4;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -185,7 +177,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
@@ -193,14 +185,13 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=0
@@ -211,7 +202,7 @@ DROP TABLE IF EXISTS tab5;
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
 
---echo # create a table with page size=8K 
+--echo # create a table with page size=8K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=8;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -220,8 +211,8 @@ let $block_size=8;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -230,7 +221,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
@@ -238,14 +229,13 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=0
@@ -256,7 +246,7 @@ DROP TABLE IF EXISTS tab5;
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
 
---echo # create a table with page size=16K 
+--echo # create a table with page size=16K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=16;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -265,8 +255,8 @@ let $block_size=16;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -275,7 +265,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
@@ -283,14 +273,13 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # test the interaction between wl6347 & wl6344 (2.2)
@@ -301,14 +290,11 @@ DROP TABLE IF EXISTS tab5;
 # check the size and compression stats of the table tab5
 #******************************************************************
 
-USE test;
-DROP TABLE IF EXISTS tab5;
-
 --echo #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
 
---echo # set the flags 
+--echo # set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_compression_level=9;
@@ -319,7 +305,7 @@ SET GLOBAL innodb_compression_level=9;
 #  with page size 1K
 #******************************************************************
 
---echo # create a table with page size=1K 
+--echo # create a table with page size=1K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=1;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -329,8 +315,8 @@ let $block_size=1;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -340,7 +326,7 @@ SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -348,7 +334,7 @@ SET @inl_val=2;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -360,7 +346,7 @@ SET @inl_val=2;
 --echo # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # set the flags 
+--echo # set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_compression_level=9;
@@ -368,16 +354,15 @@ SET GLOBAL innodb_compression_level=9;
 
 --echo # fetch the compressed page and check the stats
 --echo # The stats figure may be different/same for each restart.
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
---echo # check the stats of the table 
+--echo # check the stats of the table
 -- echo # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=1;
 --source suite/innodb/include/innodb_stats_restart.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=9
@@ -388,7 +373,7 @@ DROP TABLE IF EXISTS tab5;
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # create a table with page size=2K 
+--echo # create a table with page size=2K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=2;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -398,8 +383,8 @@ let $block_size=2;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -409,7 +394,7 @@ SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -417,7 +402,7 @@ SET @inl_val=2;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -429,7 +414,7 @@ SET @inl_val=2;
 --echo # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # set the flags 
+--echo # set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_compression_level=9;
@@ -437,16 +422,15 @@ SET GLOBAL innodb_compression_level=9;
 
 --echo # fetch the compressed page and check the stats
 --echo # The stats figure may be different/same for each restart.
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
---echo # check the stats of the table 
+--echo # check the stats of the table
 -- echo # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=1;
 --source suite/innodb/include/innodb_stats_restart.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=9
@@ -457,7 +441,7 @@ DROP TABLE IF EXISTS tab5;
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # create a table with page size=4K 
+--echo # create a table with page size=4K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=4;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -467,8 +451,8 @@ let $block_size=4;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -478,7 +462,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
@@ -486,15 +470,13 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=9
@@ -505,7 +487,7 @@ DROP TABLE IF EXISTS tab5;
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # create a table with page size=8K 
+--echo # create a table with page size=8K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=8;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -515,8 +497,8 @@ let $block_size=8;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -525,23 +507,22 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
---echo # The size of the file with 0 compress = 212992 
+--echo # The size of the file with 0 compress = 212992
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=9
@@ -552,7 +533,7 @@ DROP TABLE IF EXISTS tab5;
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # create a table with page size=16K 
+--echo # create a table with page size=16K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=16;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -562,8 +543,8 @@ let $block_size=16;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -572,7 +553,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 --echo # The size of the file with 0 compress = 344064
@@ -581,20 +562,19 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # test the interaction between wl6347 & wl6344 (2.3)
 # This testcase is to verify the table/idex level comoression stats
 # When the flags are set as follows
-# innodb_cmp_per_index_enabled=ON and 
+# innodb_cmp_per_index_enabled=ON and
 # innodb_compression_level=6 (default)
 # page size 1K,2K,4K,8K,16K
 # check the size and compression stats of the table tab5
@@ -612,7 +592,7 @@ SET GLOBAL innodb_cmp_per_index_enabled=
 
 SET GLOBAL innodb_compression_level=default;
 
---echo # create a table with page size=1K 
+--echo # create a table with page size=1K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=1;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -622,8 +602,8 @@ let $block_size=1;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -633,7 +613,7 @@ SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -641,15 +621,13 @@ SET @inl_val=2;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=Def
@@ -662,7 +640,7 @@ SET GLOBAL innodb_cmp_per_index_enabled=
 
 SET GLOBAL innodb_compression_level=default;
 
---echo # create a table with page size=4K 
+--echo # create a table with page size=4K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=4;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -672,8 +650,8 @@ let $block_size=4;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -683,15 +661,13 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
-
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=Def
@@ -704,7 +680,7 @@ SET GLOBAL innodb_cmp_per_index_enabled=
 
 SET GLOBAL innodb_compression_level=default;
 
---echo # create a table with page size=8K 
+--echo # create a table with page size=8K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=8;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -714,8 +690,8 @@ let $block_size=8;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -725,14 +701,13 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and innodb_compression_level=Def
@@ -745,7 +720,7 @@ SET GLOBAL innodb_cmp_per_index_enabled=
 
 SET GLOBAL innodb_compression_level=default;
 
---echo # create a table with page size=16K 
+--echo # create a table with page size=16K
 --echo # create indexes on each column.(total 9 indexes)
 let $block_size=16;
 --source suite/innodb/include/innodb_create_tab_indx.inc
@@ -755,8 +730,8 @@ let $block_size=16;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -766,34 +741,29 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
 # Test the interaction between wl6347 & wl6344 (2.5 & 2.6)
 # This testcase is to verify the table/idex level comoression stats
 # When the flags are set as follows
-# innodb_cmp_per_index_enabled=ON and 
+# innodb_cmp_per_index_enabled=ON and
 # Innodb_compression_failure_threshold_pct=0
 # page size 1K,2K,4K,8K,16K
 # check the size and compression stats of the table tab5
 #******************************************************************
 
-USE test;
-DROP TABLE IF EXISTS tab5;
-
 --echo #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # set the flags 
+--echo # set the flags
 SET GLOBAL innodb_compression_failure_threshold_pct=0;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
@@ -819,8 +789,8 @@ let $block_size=1;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -829,7 +799,7 @@ SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -837,7 +807,7 @@ SET @inl_val=2;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -849,7 +819,7 @@ SET @inl_val=2;
 --echo # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # set the flags 
+--echo # set the flags
 SET GLOBAL innodb_compression_failure_threshold_pct=0;
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
@@ -857,17 +827,15 @@ SET GLOBAL innodb_file_format='barracuda
 
 --echo # fetch the compressed page and check the stats
 --echo # The stats figure may be different/same for each restart.
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
---echo # check the stats of the table 
+--echo # check the stats of the table
 -- echo # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=1;
 --source suite/innodb/include/innodb_stats_restart.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and
@@ -887,8 +855,8 @@ let $block_size=2;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -897,7 +865,7 @@ SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -905,15 +873,13 @@ SET @inl_val=2;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and
@@ -933,8 +899,8 @@ let $block_size=4;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -943,7 +909,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
@@ -951,15 +917,13 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and
@@ -979,8 +943,8 @@ let $block_size=8;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -989,7 +953,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
@@ -997,15 +961,13 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
 # innodb_cmp_per_index_enabled=ON and
@@ -1025,8 +987,8 @@ let $block_size=16;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -1035,7 +997,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
@@ -1043,20 +1005,19 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # Test the interaction between wl6347 & wl6344 (2.7)
 # This testcase is to verify the table/idex level comoression stats
 # When the flags are set as follows
-# innodb_cmp_per_index_enabled=ON and 
+# innodb_cmp_per_index_enabled=ON and
 # Innodb_compression_failure_threshold_pct=10
 # page size 1K,2K,4K,8K,16K
 # check the size and compression stats of the table tab5
@@ -1066,10 +1027,7 @@ DROP TABLE IF EXISTS tab5;
 SET GLOBAL innodb_cmp_per_index_enabled=OFF;
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
-USE test;
-DROP TABLE IF EXISTS tab5;
-
---echo # set the flags 
+--echo # set the flags
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
@@ -1085,7 +1043,7 @@ SELECT @@innodb_file_per_table;
 SELECT @@innodb_compression_level;
 
 #******************************************************************
-# innodb_cmp_per_index_enabled=ON and 
+# innodb_cmp_per_index_enabled=ON and
 # Innodb_compression_failure_threshold_pct=10 with page size 1K
 #******************************************************************
 
@@ -1098,8 +1056,8 @@ let $block_size=1;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -1108,7 +1066,7 @@ SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -1116,7 +1074,7 @@ SET @inl_val=2;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -1128,7 +1086,7 @@ SET @inl_val=2;
 --echo # set the flag on (default off)
 SET GLOBAL innodb_cmp_per_index_enabled=ON;
 
---echo # set the flags 
+--echo # set the flags
 SET GLOBAL innodb_compression_failure_threshold_pct=10;
 SET GLOBAL innodb_file_per_table=on;
 SET GLOBAL innodb_file_format='barracuda';
@@ -1137,20 +1095,18 @@ SET GLOBAL innodb_compression_failure_th
 
 --echo # fetch the compressed page and check the stats
 --echo # The stats figure may be different/same for each restart.
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
---echo # check the stats of the table 
+--echo # check the stats of the table
 -- echo # testcase : pass = 1 fail = 0
 SET @comp_val=0;
 SET @uncomp_val=1;
 --source suite/innodb/include/innodb_stats_restart.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
-# innodb_cmp_per_index_enabled=ON and 
+# innodb_cmp_per_index_enabled=ON and
 # Innodb_compression_failure_threshold_pct=10 with page size 2K
 #******************************************************************
 
@@ -1168,8 +1124,8 @@ let $block_size=2;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -1178,7 +1134,7 @@ SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
@@ -1186,18 +1142,16 @@ SET @inl_val=2;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=2;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
-# innodb_cmp_per_index_enabled=ON and 
+# innodb_cmp_per_index_enabled=ON and
 # Innodb_compression_failure_threshold_pct=10 with page size 4K
 #******************************************************************
 
@@ -1214,8 +1168,8 @@ let $block_size=4;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -1224,7 +1178,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
@@ -1232,18 +1186,16 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
-# innodb_cmp_per_index_enabled=ON and 
+# innodb_cmp_per_index_enabled=ON and
 # Innodb_compression_failure_threshold_pct=10 with page size 8K
 #******************************************************************
 
@@ -1261,8 +1213,8 @@ let $block_size=8;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -1271,7 +1223,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
@@ -1279,18 +1231,16 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
+DROP TABLE tab5;
 
 #******************************************************************
-# innodb_cmp_per_index_enabled=ON and 
+# innodb_cmp_per_index_enabled=ON and
 # Innodb_compression_failure_threshold_pct=10 with page size 16K
 #******************************************************************
 
@@ -1307,8 +1257,8 @@ let $block_size=16;
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo # for determintic resons simple data should be inserted. 
---echo #insert some 100 records 
+--echo # for determintic resons simple data should be inserted.
+--echo #insert some 100 records
 let $i = 100;
 --source suite/innodb/include/innodb_load_data.inc
 
@@ -1317,7 +1267,7 @@ SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
 --echo # fetch the compressed page and check the stats
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
@@ -1325,22 +1275,19 @@ SET @inl_val=1;
 
 --echo # fetch the compressed same page once again and check the stats
 --echo # the stat figures should be same as above query
---source suite/innodb/include/innodb_fectch_records.inc
+--source suite/innodb/include/innodb_fetch_records.inc
 
 --echo # check the stats of the table & size of the table
 SET @inl_val=1;
 --source suite/innodb/include/innodb_stats_comp_index.inc
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5;
 
 #******************************************************************
 # Create multiple tables & indexes having same name in 2 diff DB's
 # Check the stats of the table. (1.1)
 #******************************************************************
 
-USE test;
-
 --echo #reset the stat table before starting next testcase
 SET GLOBAL innodb_cmp_per_index_enabled=0;
 SET GLOBAL innodb_cmp_per_index_enabled=1;
@@ -1354,11 +1301,10 @@ SET GLOBAL innodb_compression_failure_th
 --echo #create a table page size=1K
 CREATE TABLE tab5(col_1 TINYBLOB, col_2 TINYTEXT,col_3 BLOB,
 col_4 TEXT,col_5 MEDIUMBLOB,col_6 MEDIUMTEXT,
-col_7 LONGBLOB,col_8 LONGTEXT,col_9 VARCHAR(255)) 
+col_7 LONGBLOB,col_8 LONGTEXT,col_9 VARCHAR(255))
 ENGINE=INNODB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1;
 
---echo #create index
-CREATE INDEX  idx1 ON tab5(col_1(10));
+CREATE INDEX idx1 ON tab5(col_1(10));
 
 --echo #check the stats of the table
 SELECT database_name,table_name,index_name,compress_ops,compress_ops_ok
@@ -1367,40 +1313,27 @@ WHERE database_name='test' and table_nam
 ORDER BY index_name,table_name,database_name ;
 
 CREATE DATABASE sb;
-
 USE sb;
 
 --echo #create a table page size=1K (testcase-1)
 CREATE TABLE tab5(col_1 TINYBLOB, col_2 TINYTEXT,col_3 BLOB,
 col_4 TEXT,col_5 MEDIUMBLOB,col_6 MEDIUMTEXT,
-col_7 LONGBLOB,col_8 LONGTEXT,col_9 VARCHAR(255)) 
+col_7 LONGBLOB,col_8 LONGTEXT,col_9 VARCHAR(255))
 ENGINE=INNODB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1;
 
---echo #create index
-CREATE INDEX  idx1 ON tab5(col_1(10));
+CREATE INDEX idx1 ON tab5(col_1(10));
 
---echo #check the stats of the table
 SELECT database_name,table_name,index_name,compress_ops,compress_ops_ok
 FROM information_schema.innodb_cmp_per_index
 WHERE database_name='sb' and table_name='tab5'
 ORDER BY index_name,table_name,database_name ;
 
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
+DROP TABLE tab5, test.tab5;
 DROP DATABASE sb;
 
-USE test;
-
---echo #cleanup
-DROP TABLE IF EXISTS tab5;
-
---echo # reset back the flags 
+--echo # reset the flags
 eval SET GLOBAL innodb_file_per_table=default;
 eval SET GLOBAL innodb_file_format=default;
 eval SET GLOBAL innodb_cmp_per_index_enabled=default;
 eval SET GLOBAL innodb_compression_level=default;
 eval SET GLOBAL innodb_compression_failure_threshold_pct=default;
-
-
-
-

=== modified file 'storage/innobase/btr/btr0cur.cc'
--- a/storage/innobase/btr/btr0cur.cc	revid:inaam.rana@stripped10-2x0i8gwqjihd801n
+++ b/storage/innobase/btr/btr0cur.cc	revid:marko.makela@strippedkkx0o
@@ -1252,7 +1252,6 @@ btr_cur_optimistic_insert(
 	page_cur_t*	page_cursor;
 	buf_block_t*	block;
 	page_t*		page;
-	ulint		max_size;
 	rec_t*		dummy;
 	ibool		leaf;
 	ibool		reorg;
@@ -1266,9 +1265,13 @@ btr_cur_optimistic_insert(
 	block = btr_cur_get_block(cursor);
 	page = buf_block_get_frame(block);
 	index = cursor->index;
+
+	ut_ad(mtr_memo_contains(mtr, block, MTR_MEMO_PAGE_X_FIX));
 	ut_ad(!dict_index_is_online_ddl(index)
 	      || dict_index_is_clust(index)
 	      || (flags & BTR_CREATE_FLAG));
+	ut_ad(dtuple_check_typed(entry));
+
 	zip_size = buf_block_get_zip_size(block);
 #ifdef UNIV_DEBUG_VALGRIND
 	if (zip_size) {
@@ -1277,10 +1280,6 @@ btr_cur_optimistic_insert(
 	}
 #endif /* UNIV_DEBUG_VALGRIND */
 
-	if (!dtuple_check_typed_no_assert(entry)) {
-		fputs("InnoDB: Error in a tuple to insert into ", stderr);
-		dict_index_name_print(stderr, thr_get_trx(thr), index);
-	}
 #ifdef UNIV_DEBUG
 	if (btr_cur_print_record_ops && thr) {
 		btr_cur_trx_report(thr_get_trx(thr)->id, index, "insert ");
@@ -1288,8 +1287,6 @@ btr_cur_optimistic_insert(
 	}
 #endif /* UNIV_DEBUG */
 
-	ut_ad(mtr_memo_contains(mtr, block, MTR_MEMO_PAGE_X_FIX));
-	max_size = page_get_max_insert_size_after_reorganize(page, 1);
 	leaf = page_is_leaf(page);
 
 	/* Calculate the record size when entry is converted to a record */
@@ -1355,23 +1352,13 @@ too_big:
 	LIMIT_OPTIMISTIC_INSERT_DEBUG(page_get_n_recs(page),
 				      goto fail);
 
-	if (!leaf) {
-	} else if (zip_size
-		   && (page_get_data_size(page) + rec_size
-		       >= dict_index_zip_pad_optimal_page_size(index))) {
+	if (leaf && zip_size
+	    && (page_get_data_size(page) + rec_size
+		>= dict_index_zip_pad_optimal_page_size(index))) {
 		/* If compression padding tells us that insertion will
 		result in too packed up page i.e.: which is likely to
 		cause compression failure then don't do an optimistic
 		insertion. */
-		goto fail;
-	} else if (dict_index_is_clust(index) && page_get_n_recs(page) >= 2
-		   && dict_index_get_space_reserve() + rec_size > max_size
-		   && (btr_page_get_split_rec_to_right(cursor, &dummy)
-		       || btr_page_get_split_rec_to_left(cursor, &dummy))) {
-		/* If there have been many consecutive inserts, and we
-		are on the leaf level, check if we have to split the
-		page to reserve enough free space for future updates
-		of records. */
 fail:
 		err = DB_FAIL;
 fail_err:
@@ -1383,11 +1370,30 @@ fail_err:
 		return(err);
 	}
 
-	if (UNIV_UNLIKELY(max_size < BTR_CUR_PAGE_REORGANIZE_LIMIT
-			  || max_size < rec_size)
-	    && UNIV_LIKELY(page_get_n_recs(page) > 1)
-	    && page_get_max_insert_size(page, 1) < rec_size) {
+	ulint	max_size = page_get_max_insert_size_after_reorganize(page, 1);
+
+	if (page_has_garbage(page)) {
+		if ((max_size < rec_size
+		     || max_size < BTR_CUR_PAGE_REORGANIZE_LIMIT)
+		    && page_get_n_recs(page) > 1
+		    && page_get_max_insert_size(page, 1) < rec_size) {
 
+			goto fail;
+		}
+	} else if (max_size < rec_size) {
+		goto fail;
+	}
+
+	/* If there have been many consecutive inserts to the
+	clustered index leaf page of an uncompressed table, check if
+	we have to split the page to reserve enough free space for
+	future updates of records. */
+
+	if (leaf && !zip_size && dict_index_is_clust(index)
+	    && page_get_n_recs(page) >= 2
+	    && dict_index_get_space_reserve() + rec_size > max_size
+	    && (btr_page_get_split_rec_to_right(cursor, &dummy)
+		|| btr_page_get_split_rec_to_left(cursor, &dummy))) {
 		goto fail;
 	}
 
@@ -1461,12 +1467,6 @@ fail_err:
 		lock_update_insert(block, *rec);
 	}
 
-#if 0
-	fprintf(stderr, "Insert into page %lu, max ins size %lu,"
-		" rec %lu ind type %lu\n",
-		buf_block_get_page_no(block), max_size,
-		rec_size + PAGE_DIR_SLOT_SIZE, index->type);
-#endif
 	if (leaf && !dict_index_is_clust(index)) {
 		/* Update the free bits of the B-tree page in the
 		insert buffer bitmap. */

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-5.6 branch (marko.makela:4849) marko.makela4 Apr