Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
c2f39e80
Commit
c2f39e80
authored
Aug 12, 2014
by
joel9001
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#268 Adding bulk fetch MTR test and result files
parent
ebb7a85c
Changes
16
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
3629 additions
and
0 deletions
+3629
-0
mysql-test/suite/tokudb.bugs/r/bf_create_select_hash_part.result
...est/suite/tokudb.bugs/r/bf_create_select_hash_part.result
+328
-0
mysql-test/suite/tokudb.bugs/r/bf_create_select_nonpart.result
...-test/suite/tokudb.bugs/r/bf_create_select_nonpart.result
+242
-0
mysql-test/suite/tokudb.bugs/r/bf_create_select_range_part.result
...st/suite/tokudb.bugs/r/bf_create_select_range_part.result
+335
-0
mysql-test/suite/tokudb.bugs/r/bf_create_temp_select_nonpart.result
.../suite/tokudb.bugs/r/bf_create_temp_select_nonpart.result
+242
-0
mysql-test/suite/tokudb.bugs/r/bf_insert_select_dup_key_nonpart.result
...ite/tokudb.bugs/r/bf_insert_select_dup_key_nonpart.result
+207
-0
mysql-test/suite/tokudb.bugs/r/bf_insert_select_nonpart.result
...-test/suite/tokudb.bugs/r/bf_insert_select_nonpart.result
+205
-0
mysql-test/suite/tokudb.bugs/r/bf_replace_select_nonpart.result
...test/suite/tokudb.bugs/r/bf_replace_select_nonpart.result
+367
-0
mysql-test/suite/tokudb.bugs/r/bf_select_part.result
mysql-test/suite/tokudb.bugs/r/bf_select_part.result
+543
-0
mysql-test/suite/tokudb.bugs/t/bf_create_select_hash_part.test
...-test/suite/tokudb.bugs/t/bf_create_select_hash_part.test
+141
-0
mysql-test/suite/tokudb.bugs/t/bf_create_select_nonpart.test
mysql-test/suite/tokudb.bugs/t/bf_create_select_nonpart.test
+116
-0
mysql-test/suite/tokudb.bugs/t/bf_create_select_range_part.test
...test/suite/tokudb.bugs/t/bf_create_select_range_part.test
+136
-0
mysql-test/suite/tokudb.bugs/t/bf_create_temp_select_nonpart.test
...st/suite/tokudb.bugs/t/bf_create_temp_select_nonpart.test
+116
-0
mysql-test/suite/tokudb.bugs/t/bf_insert_select_dup_key_nonpart.test
...suite/tokudb.bugs/t/bf_insert_select_dup_key_nonpart.test
+125
-0
mysql-test/suite/tokudb.bugs/t/bf_insert_select_nonpart.test
mysql-test/suite/tokudb.bugs/t/bf_insert_select_nonpart.test
+120
-0
mysql-test/suite/tokudb.bugs/t/bf_replace_select_nonpart.test
...l-test/suite/tokudb.bugs/t/bf_replace_select_nonpart.test
+188
-0
mysql-test/suite/tokudb.bugs/t/bf_select_part.test
mysql-test/suite/tokudb.bugs/t/bf_select_part.test
+218
-0
No files found.
mysql-test/suite/tokudb.bugs/r/bf_create_select_hash_part.result
0 → 100644
View file @
c2f39e80
set default_storage_engine='tokudb';
drop table if exists t,t1,t2,t3;
CREATE TABLE `t` (
`num` int(10) unsigned auto_increment NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
);
INSERT INTO t values (null,null);
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
SELECT count(*) FROM t;
count(*)
8388608
CREATE TABLE `t1` (
`num` int(10) unsigned NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
) as select * from t;
CREATE TABLE `t2` (
`num` int(10) unsigned NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
) PARTITION BY HASH (num)
PARTITIONS 8 as select * from t;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2;
DROP TABLE t3;
1
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
CREATE TABLE t3 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t3;
1
drop table t,t1,t2;
mysql-test/suite/tokudb.bugs/r/bf_create_select_nonpart.result
0 → 100644
View file @
c2f39e80
set default_storage_engine='tokudb';
drop table if exists t,t1,t2;
CREATE TABLE `t` (
`num` int(10) unsigned auto_increment NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
);
INSERT INTO t values (null,null);
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
SELECT count(*) FROM t;
count(*)
8388608
CREATE TABLE `t1` (
`num` int(10) unsigned NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
) as select * from t;
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
CREATE TABLE t2 AS SELECT count(*) from t1;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1;
DROP TABLE t2;
1
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
CREATE TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TABLE t2;
1
drop table t,t1;
mysql-test/suite/tokudb.bugs/r/bf_create_select_range_part.result
0 → 100644
View file @
c2f39e80
set default_storage_engine='tokudb';
drop table if exists t,t1,t2;
CREATE TABLE `t` (
`num` int(10) unsigned auto_increment NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
);
INSERT INTO t values (null,null);
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
SELECT count(*) FROM t;
count(*)
8388608
CREATE TABLE `t1` (
`num` int(10) unsigned NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
) as select * from t;
CREATE TABLE `t2` (
`num` int(10) unsigned NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
) PARTITION BY RANGE (num)
(PARTITION p0 VALUES LESS THAN (1000000),
PARTITION p1 VALUES LESS THAN (2000000),
PARTITION p2 VALUES LESS THAN (3000000),
PARTITION p3 VALUES LESS THAN (4000000),
PARTITION p4 VALUES LESS THAN (5000000),
PARTITION p5 VALUES LESS THAN (6000000),
PARTITION p6 VALUES LESS THAN (7000000),
PARTITION p7 VALUES LESS THAN MAXVALUE) as select * from t;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1;
count(*)
8388608
DROP TABLE t3;
CREATE TABLE t4 AS SELECT count(*) from t2;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2;
DROP TABLE t4;
1
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE `t3` (`x` bigint);
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
DROP TABLE t3;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
CREATE TABLE t4 AS SELECT count(*) from t2 where num > 7000000;
DROP TABLE t4;
1
drop table t,t1,t2;
mysql-test/suite/tokudb.bugs/r/bf_create_temp_select_nonpart.result
0 → 100644
View file @
c2f39e80
set default_storage_engine='tokudb';
drop table if exists t,t1,t2;
CREATE TABLE `t` (
`num` int(10) unsigned auto_increment NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
);
INSERT INTO t values (null,null);
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
SELECT count(*) FROM t;
count(*)
8388608
CREATE TABLE `t1` (
`num` int(10) unsigned NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
) as select * from t;
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1;
DROP TEMPORARY TABLE t2;
1
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
CREATE TEMPORARY TABLE t2 AS SELECT count(*) from t1 where num > 7000000;
DROP TEMPORARY TABLE t2;
1
drop table t,t1;
mysql-test/suite/tokudb.bugs/r/bf_insert_select_dup_key_nonpart.result
0 → 100644
View file @
c2f39e80
set default_storage_engine='tokudb';
drop table if exists t,t1,t2;
CREATE TABLE `t` (
`num` int(10) unsigned auto_increment NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
);
INSERT INTO t values (null,null);
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
SELECT count(*) FROM t;
count(*)
8388608
CREATE TABLE `t1` (
`num` int(10) unsigned NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
) as select * from t;
CREATE TABLE `t2` (
`num` int(10) unsigned auto_increment NOT NULL,
`count` bigint(20) NOT NULL,
UNIQUE (num)
) ENGINE=TokuDB DEFAULT CHARSET=latin1;
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 on DUPLICATE KEY UPDATE count=count+1;
1
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
INSERT into t2 (num,count) SELECT NULL,count(*) from t1 where num > 7000000 on DUPLICATE KEY UPDATE count=count+1;
1
drop table t,t1,t2;
mysql-test/suite/tokudb.bugs/r/bf_insert_select_nonpart.result
0 → 100644
View file @
c2f39e80
set default_storage_engine='tokudb';
drop table if exists t,t1,t2;
CREATE TABLE `t` (
`num` int(10) unsigned auto_increment NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
);
INSERT INTO t values (null,null);
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
INSERT INTO t SELECT null,val FROM t;
SELECT count(*) FROM t;
count(*)
8388608
CREATE TABLE `t1` (
`num` int(10) unsigned NOT NULL,
`val` varchar(32) DEFAULT NULL,
PRIMARY KEY (`num`)
) as select * from t;
CREATE TABLE `t2` (
`count` bigint(20) NOT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1;
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
SELECT count(*) from t1;
count(*)
8388608
INSERT into t2 SELECT count(*) from t1;
INSERT into t2 SELECT count(*) from t1;
INSERT into t2 SELECT count(*) from t1;
INSERT into t2 SELECT count(*) from t1;
INSERT into t2 SELECT count(*) from t1;
INSERT into t2 SELECT count(*) from t1;
INSERT into t2 SELECT count(*) from t1;
INSERT into t2 SELECT count(*) from t1;
INSERT into t2 SELECT count(*) from t1;
INSERT into t2 SELECT count(*) from t1;
1
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
SELECT count(*) from t1 where num > 7000000;
count(*)
1847274
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
INSERT into t2 SELECT count(*) from t1 where num > 7000000;
1
drop table t,t1,t2;
mysql-test/suite/tokudb.bugs/r/bf_replace_select_nonpart.result
0 → 100644
View file @
c2f39e80
This diff is collapsed.
Click to expand it.
mysql-test/suite/tokudb.bugs/r/bf_select_part.result
0 → 100644
View file @
c2f39e80
This diff is collapsed.
Click to expand it.
mysql-test/suite/tokudb.bugs/t/bf_create_select_hash_part.test
0 → 100644
View file @
c2f39e80
# Verify that index and range scans are not slow
# on tables during create select statements
# due to tokudb bulk fetch not being used
source
include
/
have_tokudb
.
inc
;
source
include
/
have_partition
.
inc
;
set
default_storage_engine
=
'tokudb'
;
disable_warnings
;
drop
table
if
exists
t
,
t1
,
t2
,
t3
;
enable_warnings
;
let
$maxq
=
10
;
CREATE
TABLE
`t`
(
`num`
int
(
10
)
unsigned
auto_increment
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
);
# put 8M rows into t
INSERT
INTO
t
values
(
null
,
null
);
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
SELECT
count
(
*
)
FROM
t
;
# Create base table (control table) from source table t
CREATE
TABLE
`t1`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
as
select
*
from
t
;
# Create source hash partitioned table from source table t
CREATE
TABLE
`t2`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
PARTITION
BY
HASH
(
num
)
PARTITIONS
8
as
select
*
from
t
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
CREATE
TABLE
`t3`
(
`x`
bigint
);
SELECT
count
(
*
)
from
t1
;
DROP
TABLE
t3
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
CREATE
TABLE
t3
AS
SELECT
count
(
*
)
from
t2
;
DROP
TABLE
t3
;
inc
$i
;
}
let
$time_elapsed_create_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_create_select seconds.;
# This check evaluates whether the time elapsed during the create select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
# Additionally, it is important to note that 1.5 is the multiplier applied to the time_elapsed_select
# value because it appears that MySQL 5.5.39 uses a sorted index scan during the create select statement
# while Percona Server 5.6 uses an unsorted index scan.
# The issue has been resolved in MySQL 5.6 but still persists in Maria 10.0.12
# in the defect found at https://mariadb.atlassian.net/browse/MDEV-6547.
let
$verdict
=
`select abs($time_elapsed_create_select - $time_elapsed_select) <= 1.5 * $time_elapsed_select`
;
echo
$verdict
;
if
(
!
$verdict
)
{
echo
index
scan
t2
$time_elapsed_create_select
$time_elapsed_select
;
}
let
$maxrq
=
30
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
CREATE
TABLE
`t3`
(
`x`
bigint
);
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
DROP
TABLE
t3
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
CREATE
TABLE
t3
AS
SELECT
count
(
*
)
from
t2
where
num
>
7000000
;
DROP
TABLE
t3
;
inc
$i
;
}
let
$time_elapsed_create_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_create_select seconds.;
# This check evaluates whether the time elapsed during the create select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
# Additionally, it is important to note that 1.5 is the multiplier applied to the time_elapsed_select
# value because it appears that MySQL 5.5.39 uses a sorted index scan during the create select statement
# while Percona Server 5.6 uses an unsorted index scan.
# The issue has been resolved in MySQL 5.6 but still persists in Maria 10.0.12
# in the defect found at https://mariadb.atlassian.net/browse/MDEV-6547.
let
$verdict
=
`select abs($time_elapsed_create_select - $time_elapsed_select) <= 1.5 * $time_elapsed_select`
;
echo
$verdict
;
if
(
!
$verdict
)
{
echo
range
scan
t2
$time_elapsed_create_select
$time_elapsed_select
;
}
drop
table
t
,
t1
,
t2
;
mysql-test/suite/tokudb.bugs/t/bf_create_select_nonpart.test
0 → 100644
View file @
c2f39e80
# Verify that index and range scans are not slow
# on tables during create select statements
# due to tokudb bulk fetch not being used
source
include
/
have_tokudb
.
inc
;
set
default_storage_engine
=
'tokudb'
;
disable_warnings
;
drop
table
if
exists
t
,
t1
,
t2
;
enable_warnings
;
let
$maxq
=
10
;
CREATE
TABLE
`t`
(
`num`
int
(
10
)
unsigned
auto_increment
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
);
# put 8M rows into t
INSERT
INTO
t
values
(
null
,
null
);
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
SELECT
count
(
*
)
FROM
t
;
# Create first table from source table t
CREATE
TABLE
`t1`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
as
select
*
from
t
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
CREATE
TABLE
t2
AS
SELECT
count
(
*
)
from
t1
;
DROP
TABLE
t2
;
inc
$i
;
}
let
$time_elapsed_create_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_create_select seconds.;
# This check evaluates whether the time elapsed during the create select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_create_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
let
$maxrq
=
30
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
CREATE
TABLE
t2
AS
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
DROP
TABLE
t2
;
inc
$i
;
}
let
$time_elapsed_create_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_create_select seconds.;
# This check evaluates whether the time elapsed during the create select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_create_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
drop
table
t
,
t1
;
mysql-test/suite/tokudb.bugs/t/bf_create_select_range_part.test
0 → 100644
View file @
c2f39e80
# Verify that index and range scans are not slow
# on tables during create select statements
# due to tokudb bulk fetch not being used
source
include
/
have_tokudb
.
inc
;
source
include
/
have_partition
.
inc
;
set
default_storage_engine
=
'tokudb'
;
disable_warnings
;
drop
table
if
exists
t
,
t1
,
t2
;
enable_warnings
;
let
$maxq
=
10
;
CREATE
TABLE
`t`
(
`num`
int
(
10
)
unsigned
auto_increment
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
);
# put 8M rows into t
INSERT
INTO
t
values
(
null
,
null
);
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
SELECT
count
(
*
)
FROM
t
;
# Create base table (control table) from source table t
CREATE
TABLE
`t1`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
as
select
*
from
t
;
# Create source range partitioned table from source table t
CREATE
TABLE
`t2`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
PARTITION
BY
RANGE
(
num
)
(
PARTITION
p0
VALUES
LESS
THAN
(
1000000
),
PARTITION
p1
VALUES
LESS
THAN
(
2000000
),
PARTITION
p2
VALUES
LESS
THAN
(
3000000
),
PARTITION
p3
VALUES
LESS
THAN
(
4000000
),
PARTITION
p4
VALUES
LESS
THAN
(
5000000
),
PARTITION
p5
VALUES
LESS
THAN
(
6000000
),
PARTITION
p6
VALUES
LESS
THAN
(
7000000
),
PARTITION
p7
VALUES
LESS
THAN
MAXVALUE
)
as
select
*
from
t
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
CREATE
TABLE
`t3`
(
`x`
bigint
);
SELECT
count
(
*
)
from
t1
;
DROP
TABLE
t3
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
CREATE
TABLE
t4
AS
SELECT
count
(
*
)
from
t2
;
DROP
TABLE
t4
;
inc
$i
;
}
let
$time_elapsed_create_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_create_select seconds.;
# This check evaluates whether the time elapsed during the create select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_create_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
let
$maxrq
=
30
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
CREATE
TABLE
`t3`
(
`x`
bigint
);
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
DROP
TABLE
t3
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
CREATE
TABLE
t4
AS
SELECT
count
(
*
)
from
t2
where
num
>
7000000
;
DROP
TABLE
t4
;
inc
$i
;
}
let
$time_elapsed_create_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_create_select seconds.;
# This check evaluates whether the time elapsed during the create select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_create_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
drop
table
t
,
t1
,
t2
;
mysql-test/suite/tokudb.bugs/t/bf_create_temp_select_nonpart.test
0 → 100644
View file @
c2f39e80
# Verify that index and range scans are not slow
# on temporary tables during create select statements
# due to tokudb bulk fetch not being used
source
include
/
have_tokudb
.
inc
;
set
default_storage_engine
=
'tokudb'
;
disable_warnings
;
drop
table
if
exists
t
,
t1
,
t2
;
enable_warnings
;
let
$maxq
=
10
;
CREATE
TABLE
`t`
(
`num`
int
(
10
)
unsigned
auto_increment
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
);
# put 8M rows into t
INSERT
INTO
t
values
(
null
,
null
);
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
SELECT
count
(
*
)
FROM
t
;
# Create first table from source table t
CREATE
TABLE
`t1`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
as
select
*
from
t
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
CREATE
TEMPORARY
TABLE
t2
AS
SELECT
count
(
*
)
from
t1
;
DROP
TEMPORARY
TABLE
t2
;
inc
$i
;
}
let
$time_elapsed_create_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_create_select seconds.;
# This check evaluates whether the time elapsed during the create select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_create_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
let
$maxrq
=
30
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Range scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
CREATE
TEMPORARY
TABLE
t2
AS
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
DROP
TEMPORARY
TABLE
t2
;
inc
$i
;
}
let
$time_elapsed_create_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Range scans took $time_elapsed_create_select seconds.;
# This check evaluates whether the time elapsed during the create select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_create_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
drop
table
t
,
t1
;
mysql-test/suite/tokudb.bugs/t/bf_insert_select_dup_key_nonpart.test
0 → 100644
View file @
c2f39e80
# Verify that index and range scans are not slow
# on tables during insert select on duplicate key statements
# due to tokudb bulk fetch not being used.
# In this test case, the on duplicate key condition does not need to fire
# since the performance of the embedded select statement is all we are measuring.
source
include
/
have_tokudb
.
inc
;
set
default_storage_engine
=
'tokudb'
;
disable_warnings
;
drop
table
if
exists
t
,
t1
,
t2
;
enable_warnings
;
let
$maxq
=
10
;
CREATE
TABLE
`t`
(
`num`
int
(
10
)
unsigned
auto_increment
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
);
# put 8M rows into t
INSERT
INTO
t
values
(
null
,
null
);
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
SELECT
count
(
*
)
FROM
t
;
# Create first table from source table t
CREATE
TABLE
`t1`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
as
select
*
from
t
;
# Create second table t2 that will serve as the target for the insert select statment
CREATE
TABLE
`t2`
(
`num`
int
(
10
)
unsigned
auto_increment
NOT
NULL
,
`count`
bigint
(
20
)
NOT
NULL
,
UNIQUE
(
num
)
)
ENGINE
=
TokuDB
DEFAULT
CHARSET
=
latin1
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
INSERT
into
t2
(
num
,
count
)
SELECT
NULL
,
count
(
*
)
from
t1
on
DUPLICATE
KEY
UPDATE
count
=
count
+
1
;
inc
$i
;
}
let
$time_elapsed_insert_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_insert_select seconds.;
# This check evaluates whether the time elapsed during the insert select on duplicate key statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_insert_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
let
$maxrq
=
30
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Range scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
INSERT
into
t2
(
num
,
count
)
SELECT
NULL
,
count
(
*
)
from
t1
where
num
>
7000000
on
DUPLICATE
KEY
UPDATE
count
=
count
+
1
;
inc
$i
;
}
let
$time_elapsed_insert_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Range scans took $time_elapsed_insert_select seconds.;
# This check evaluates whether the time elapsed during the insert select on duplicate key statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_insert_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
enable_warnings
;
drop
table
t
,
t1
,
t2
;
mysql-test/suite/tokudb.bugs/t/bf_insert_select_nonpart.test
0 → 100644
View file @
c2f39e80
# Verify that index and range scans are not slow
# on tables during insert select statements
# due to tokudb bulk fetch not being used
source
include
/
have_tokudb
.
inc
;
set
default_storage_engine
=
'tokudb'
;
disable_warnings
;
drop
table
if
exists
t
,
t1
,
t2
;
enable_warnings
;
let
$maxq
=
10
;
CREATE
TABLE
`t`
(
`num`
int
(
10
)
unsigned
auto_increment
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
);
# put 8M rows into t
INSERT
INTO
t
values
(
null
,
null
);
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
SELECT
count
(
*
)
FROM
t
;
# Create first table from source table t
CREATE
TABLE
`t1`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
as
select
*
from
t
;
# Create second table t2 that will serve as the target for the insert select statment
CREATE
TABLE
`t2`
(
`count`
bigint
(
20
)
NOT
NULL
)
ENGINE
=
TokuDB
DEFAULT
CHARSET
=
latin1
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
INSERT
into
t2
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_insert_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_insert_select seconds.;
# This check evaluates whether the time elapsed during the insert select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_insert_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
let
$maxrq
=
30
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# This check evaluates whether the time elapsed during the insert select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
#echo Range scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
INSERT
into
t2
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_insert_select
=
`select to_seconds(now()) - $s`
;
# This check evaluates whether the time elapsed during the insert select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
#echo Range scans took $time_elapsed_insert_select seconds.;
# This check evaluates whether the time elapsed during the insert select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_insert_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
drop
table
t
,
t1
,
t2
;
mysql-test/suite/tokudb.bugs/t/bf_replace_select_nonpart.test
0 → 100644
View file @
c2f39e80
# Verify that index and range scans are not slow
# on tables during replace select and insert ignore statements
# due to tokudb bulk fetch not being used
source
include
/
have_tokudb
.
inc
;
set
default_storage_engine
=
'tokudb'
;
disable_warnings
;
drop
table
if
exists
t
,
t1
,
t2
;
enable_warnings
;
let
$maxq
=
10
;
CREATE
TABLE
`t`
(
`num`
int
(
10
)
unsigned
auto_increment
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
);
# put 8M rows into t
INSERT
INTO
t
values
(
null
,
null
);
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
SELECT
count
(
*
)
FROM
t
;
# Create first table from source table t
CREATE
TABLE
`t1`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
as
select
*
from
t
;
# Create second table t2 that will serve as the target for the replace select statment
CREATE
TABLE
`t2`
(
`count`
bigint
(
20
)
NOT
NULL
)
ENGINE
=
TokuDB
DEFAULT
CHARSET
=
latin1
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
REPLACE
into
t2
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_replace_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_replace_select seconds.;
# This check evaluates whether the time elapsed during the replace select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_replace_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
##############################################################
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
INSERT
IGNORE
into
t2
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_insert_ignore_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_insert_ignore_select seconds.;
# This check evaluates whether the time elapsed during the insert ignore select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_insert_ignore_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
##################################################################
let
$maxrq
=
30
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Range scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
REPLACE
into
t2
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_replace_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Range scans took $time_elapsed_replace_select seconds.;
# This check evaluates whether the time elapsed during the replace select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_replace_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
####################################################################
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Range scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
INSERT
IGNORE
into
t2
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_insert_ignore_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Range scans took $time_elapsed_insert_ignore_select seconds.;
# This check evaluates whether the time elapsed during the insert ignore select statement is on par
# with the select statement, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_insert_ignore_select - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
#########################################################################
drop
table
t
,
t1
,
t2
;
mysql-test/suite/tokudb.bugs/t/bf_select_part.test
0 → 100644
View file @
c2f39e80
# Verify that index and range scans are not slow
# on tables during create select statements
# against hash and range partitioned tables
# due to tokudb bulk fetch not being used
source
include
/
have_tokudb
.
inc
;
source
include
/
have_partition
.
inc
;
set
default_storage_engine
=
'tokudb'
;
disable_warnings
;
drop
table
if
exists
t
,
t1
,
t2
,
t3
;
enable_warnings
;
let
$maxq
=
10
;
CREATE
TABLE
`t`
(
`num`
int
(
10
)
unsigned
auto_increment
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
);
# put 8M rows into t
INSERT
INTO
t
values
(
null
,
null
);
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
INSERT
INTO
t
SELECT
null
,
val
FROM
t
;
SELECT
count
(
*
)
FROM
t
;
# Create first table from source table t
CREATE
TABLE
`t1`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
as
select
*
from
t
;
# Create second table from source table t
CREATE
TABLE
`t2`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
PARTITION
BY
HASH
(
num
)
PARTITIONS
8
as
select
*
from
t
;
# Create third table from source table t;
CREATE
TABLE
`t3`
(
`num`
int
(
10
)
unsigned
NOT
NULL
,
`val`
varchar
(
32
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`num`
)
)
PARTITION
BY
RANGE
(
num
)
(
PARTITION
p0
VALUES
LESS
THAN
(
1000000
),
PARTITION
p1
VALUES
LESS
THAN
(
2000000
),
PARTITION
p2
VALUES
LESS
THAN
(
3000000
),
PARTITION
p3
VALUES
LESS
THAN
(
4000000
),
PARTITION
p4
VALUES
LESS
THAN
(
5000000
),
PARTITION
p5
VALUES
LESS
THAN
(
6000000
),
PARTITION
p6
VALUES
LESS
THAN
(
7000000
),
PARTITION
p7
VALUES
LESS
THAN
MAXVALUE
)
as
select
*
from
t
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
# echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
SELECT
count
(
*
)
from
t2
;
inc
$i
;
}
let
$time_elapsed_select_hash
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
# echo Index scans took $time_elapsed_select_hash seconds.;
# This check evaluates whether the time elapsed during the select statement
# against a hashed partition table is on par with the select statment
# against a non-partitioned table, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_select_hash - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
if
(
!
$verdict
)
{
echo
index
scan
t2
$time_elapsed_select_hash
$time_elapsed_select
;
}
######################################################################
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
SELECT
count
(
*
)
from
t1
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxq
)
{
SELECT
count
(
*
)
from
t3
;
inc
$i
;
}
let
$time_elapsed_select_range
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select_range seconds.;
# This check evaluates whether the time elapsed during the select statement
# against a range partition table is on par with the select statment
# against a non-partitioned table, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_select_range - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
if
(
!
$verdict
)
{
echo
index
scan
t3
$time_elapsed_select_range
$time_elapsed_select
;
}
#########################################################################
let
$maxrq
=
30
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
SELECT
count
(
*
)
from
t2
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_select_hash
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select_hash seconds.;
# This check evaluates whether the time elapsed during the select statement
# against a hash partition table is on par with the select statment
# against a non-partitioned table, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_select_hash - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
if
(
!
$verdict
)
{
echo
range
scan
t2
$time_elapsed_select_hash
$time_elapsed_select
;
}
#########################################################################
let
$maxrq
=
30
;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
SELECT
count
(
*
)
from
t1
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_select
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select seconds.;
let
$s
=
`select to_seconds(now())`
;
let
$i
=
0
;
while
(
$i
<
$maxrq
)
{
SELECT
count
(
*
)
from
t3
where
num
>
7000000
;
inc
$i
;
}
let
$time_elapsed_select_range
=
`select to_seconds(now()) - $s`
;
# The following line can be used to display the time elapsed data
# which could be useful for debugging.
#echo Index scans took $time_elapsed_select_range seconds.;
# This check evaluates whether the time elapsed during the select statement
# against a range partition table is on par with the select statment
# against a non-partitioned table, which will confirm that bulk fetch is in fact being used.
let
$verdict
=
`select abs($time_elapsed_select_range - $time_elapsed_select) <= $time_elapsed_select`
;
echo
$verdict
;
if
(
!
$verdict
)
{
echo
range
scan
t3
$time_elapsed_select_range
$time_elapsed_select
;
}
drop
table
t
,
t1
,
t2
,
t3
;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment