Commit 525c3c24 authored by Sergei Golubchik's avatar Sergei Golubchik

TokuDB: make the default value for the table compression= attribute to come

from the variable @@session.tokudb_row_format
parent 4574cf43
......@@ -245,9 +245,7 @@ extern "C" {
ha_create_table_option tokudb_table_options[]=
{
HA_TOPTION_ENUM("compression", row_format,
"TOKUDB_UNCOMPRESSED,TOKUDB_ZLIB,TOKUDB_QUICKLZ,"
"TOKUDB_LZMA,TOKUDB_FAST,TOKUDB_SMALL", 0),
HA_TOPTION_SYSVAR("compression", row_format, row_format),
HA_TOPTION_END
};
......
......@@ -376,7 +376,7 @@ t1 CREATE TABLE `t1` (
`t1_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
PRIMARY KEY (`t1_id`),
KEY `t1_name` (`t1_name`)
) ENGINE=TokuDB AUTO_INCREMENT=1003 DEFAULT CHARSET=latin1
) ENGINE=TokuDB AUTO_INCREMENT=1003 DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE `t1`;
create table t1(a int not null auto_increment primary key);
create table t2(a int not null auto_increment primary key, t1a int);
......
......@@ -7,19 +7,19 @@ Table Create Table
t CREATE TABLE `t` (
`a` char(100) NOT NULL DEFAULT '',
`b` binary(200) NOT NULL DEFAULT '\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a CHAR(101) NOT NULL DEFAULT 'a';
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` char(101) NOT NULL DEFAULT 'a',
`b` binary(200) NOT NULL DEFAULT '\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN b b BINARY(201) NOT NULL DEFAULT 'b';
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` char(101) NOT NULL DEFAULT 'a',
`b` binary(201) NOT NULL DEFAULT 'b\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE t;
......@@ -7,31 +7,31 @@ SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` tinyint(4) DEFAULT '100'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a SMALLINT DEFAULT 200;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` smallint(6) DEFAULT '200'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a MEDIUMINT DEFAULT 300;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` mediumint(9) DEFAULT '300'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a INT DEFAULT 400;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` int(11) DEFAULT '400'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a BIGINT DEFAULT 500;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` bigint(20) DEFAULT '500'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE t;
CREATE TABLE t (a TINYINT NOT NULL DEFAULT 1);
ALTER TABLE t CHANGE COLUMN a a TINYINT NOT NULL DEFAULT 100;
......@@ -39,31 +39,31 @@ SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` tinyint(4) NOT NULL DEFAULT '100'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a SMALLINT NOT NULL DEFAULT 200;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` smallint(6) NOT NULL DEFAULT '200'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a MEDIUMINT NOT NULL DEFAULT 300;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` mediumint(9) NOT NULL DEFAULT '300'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a INT NOT NULL DEFAULT 400;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` int(11) NOT NULL DEFAULT '400'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a BIGINT NOT NULL DEFAULT 500;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` bigint(20) NOT NULL DEFAULT '500'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE t;
CREATE TABLE t (a TINYINT UNSIGNED DEFAULT 1);
ALTER TABLE t CHANGE COLUMN a a TINYINT UNSIGNED DEFAULT 100;
......@@ -71,31 +71,31 @@ SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` tinyint(3) unsigned DEFAULT '100'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a SMALLINT UNSIGNED DEFAULT 200;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` smallint(5) unsigned DEFAULT '200'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a MEDIUMINT UNSIGNED DEFAULT 300;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` mediumint(8) unsigned DEFAULT '300'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a INT UNSIGNED DEFAULT 400;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` int(10) unsigned DEFAULT '400'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a BIGINT UNSIGNED DEFAULT 500;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` bigint(20) unsigned DEFAULT '500'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE t;
CREATE TABLE t (a TINYINT UNSIGNED NOT NULL DEFAULT 1);
ALTER TABLE t CHANGE COLUMN a a TINYINT UNSIGNED NOT NULL DEFAULT 100;
......@@ -103,29 +103,29 @@ SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` tinyint(3) unsigned NOT NULL DEFAULT '100'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a SMALLINT UNSIGNED NOT NULL DEFAULT 200;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` smallint(5) unsigned NOT NULL DEFAULT '200'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a MEDIUMINT UNSIGNED NOT NULL DEFAULT 300;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` mediumint(8) unsigned NOT NULL DEFAULT '300'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a INT UNSIGNED NOT NULL DEFAULT 400;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` int(10) unsigned NOT NULL DEFAULT '400'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a BIGINT UNSIGNED NOT NULL DEFAULT 500;
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` bigint(20) unsigned NOT NULL DEFAULT '500'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE t;
......@@ -5,7 +5,7 @@ SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` varbinary(1) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARBINARY(2);
ALTER TABLE t CHANGE COLUMN a a VARBINARY(2);
ALTER TABLE t CHANGE COLUMN a a VARBINARY(3);
......
......@@ -6,21 +6,21 @@ Table Create Table
t CREATE TABLE `t` (
`a` varbinary(100) NOT NULL DEFAULT '',
`b` varbinary(256) NOT NULL DEFAULT ''
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARBINARY(255) NOT NULL DEFAULT 'a';
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` varbinary(255) NOT NULL DEFAULT 'a',
`b` varbinary(256) NOT NULL DEFAULT ''
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARBINARY(256) NOT NULL DEFAULT 'b';
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` varbinary(256) NOT NULL DEFAULT 'b',
`b` varbinary(256) NOT NULL DEFAULT ''
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN b b VARBINARY(255) NOT NULL DEFAULT 'c';
ERROR 42000: Table 't' uses an extension that doesn't exist in this XYZ version
ALTER TABLE t CHANGE COLUMN b b VARBINARY(1024) NOT NULL DEFAULT 'd';
......@@ -29,7 +29,7 @@ Table Create Table
t CREATE TABLE `t` (
`a` varbinary(256) NOT NULL DEFAULT 'b',
`b` varbinary(1024) NOT NULL DEFAULT 'd'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN b b VARBINARY(256) NOT NULL DEFAULT 'e';
ERROR 42000: Table 't' uses an extension that doesn't exist in this XYZ version
DROP TABLE t;
......@@ -12,14 +12,14 @@ Table Create Table
t CREATE TABLE `t` (
`a` varbinary(101) DEFAULT NULL,
`b` varbinary(100) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARBINARY(200);
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` varbinary(200) DEFAULT NULL,
`b` varbinary(100) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
SELECT * FROM t;
a b
hi there
......@@ -38,7 +38,7 @@ t CREATE TABLE `t` (
`i` int(11) DEFAULT NULL,
`a` varbinary(101) DEFAULT NULL,
`b` varbinary(100) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARBINARY(200);
SHOW CREATE TABLE t;
Table Create Table
......@@ -46,7 +46,7 @@ t CREATE TABLE `t` (
`i` int(11) DEFAULT NULL,
`a` varbinary(200) DEFAULT NULL,
`b` varbinary(100) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
SELECT * FROM t;
i a b
1 hi there
......
......@@ -5,7 +5,7 @@ SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` varchar(1) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARCHAR(2);
ALTER TABLE t CHANGE COLUMN a a VARCHAR(2);
ALTER TABLE t CHANGE COLUMN a a VARCHAR(3);
......
......@@ -6,21 +6,21 @@ Table Create Table
t CREATE TABLE `t` (
`a` varchar(100) NOT NULL DEFAULT '',
`b` varchar(256) NOT NULL DEFAULT ''
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARCHAR(255) NOT NULL DEFAULT 'a';
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` varchar(255) NOT NULL DEFAULT 'a',
`b` varchar(256) NOT NULL DEFAULT ''
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARCHAR(256) NOT NULL DEFAULT 'b';
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` varchar(256) NOT NULL DEFAULT 'b',
`b` varchar(256) NOT NULL DEFAULT ''
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN b b VARCHAR(255) NOT NULL DEFAULT 'c';
ERROR 42000: Table 't' uses an extension that doesn't exist in this XYZ version
ALTER TABLE t CHANGE COLUMN b b VARCHAR(1024) NOT NULL DEFAULT 'd';
......@@ -29,7 +29,7 @@ Table Create Table
t CREATE TABLE `t` (
`a` varchar(256) NOT NULL DEFAULT 'b',
`b` varchar(1024) NOT NULL DEFAULT 'd'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN b b VARCHAR(256) NOT NULL DEFAULT 'e';
ERROR 42000: Table 't' uses an extension that doesn't exist in this XYZ version
DROP TABLE t;
......@@ -8,7 +8,7 @@ t CREATE TABLE `t` (
`a` varchar(32) DEFAULT NULL,
`b` varchar(32) DEFAULT NULL,
KEY `a` (`a`(2))
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARCHAR(100);
ERROR 42000: Table 't' uses an extension that doesn't exist in this XYZ version
ALTER TABLE t CHANGE COLUMN a a VARCHAR(256);
......
......@@ -8,7 +8,7 @@ t CREATE TABLE `t` (
`a` varchar(32) DEFAULT NULL,
`b` varchar(32) DEFAULT NULL,
KEY `a` (`a`(2))
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN b b VARCHAR(100);
ALTER TABLE t CHANGE COLUMN b b VARCHAR(256);
DROP TABLE t;
......@@ -12,14 +12,14 @@ Table Create Table
t CREATE TABLE `t` (
`a` varchar(101) DEFAULT NULL,
`b` varchar(100) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARCHAR(200);
SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` varchar(200) DEFAULT NULL,
`b` varchar(100) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
SELECT * FROM t;
a b
hi there
......@@ -38,7 +38,7 @@ t CREATE TABLE `t` (
`i` int(11) DEFAULT NULL,
`a` varchar(101) DEFAULT NULL,
`b` varchar(100) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE t CHANGE COLUMN a a VARCHAR(200);
SHOW CREATE TABLE t;
Table Create Table
......@@ -46,7 +46,7 @@ t CREATE TABLE `t` (
`i` int(11) DEFAULT NULL,
`a` varchar(200) DEFAULT NULL,
`b` varchar(100) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
SELECT * FROM t;
i a b
1 hi there
......
......@@ -1009,14 +1009,14 @@ s CREATE TABLE `s` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join * from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s ALL NULL NULL NULL NULL 1000
......@@ -1030,7 +1030,7 @@ s CREATE TABLE `s` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `b` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1038,7 +1038,7 @@ t CREATE TABLE `t` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `b` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join * from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s index b b 5 NULL 1000 Using where; Using index
......
......@@ -1009,14 +1009,14 @@ s CREATE TABLE `s` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join * from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s ALL NULL NULL NULL NULL 1000
......@@ -1030,7 +1030,7 @@ s CREATE TABLE `s` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1038,7 +1038,7 @@ t CREATE TABLE `t` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join * from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s ALL b NULL NULL NULL 1000 Using where
......@@ -1057,7 +1057,7 @@ s CREATE TABLE `s` (
`c` int(11) DEFAULT NULL,
KEY `b` (`b`),
KEY `b_2` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1066,7 +1066,7 @@ t CREATE TABLE `t` (
`c` int(11) DEFAULT NULL,
KEY `b` (`b`),
KEY `b_2` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join * from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s index b,b_2 b_2 5 NULL 1000 Using where; Using index
......@@ -1080,7 +1080,7 @@ s CREATE TABLE `s` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `b_2` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1088,7 +1088,7 @@ t CREATE TABLE `t` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `b_2` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join * from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s index b_2 b_2 5 NULL 1000 Using where; Using index
......@@ -1107,7 +1107,7 @@ s CREATE TABLE `s` (
`c` int(11) DEFAULT NULL,
KEY `b_2` (`b`) `clustering`=yes,
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1116,7 +1116,7 @@ t CREATE TABLE `t` (
`c` int(11) DEFAULT NULL,
KEY `b_2` (`b`) `clustering`=yes,
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join * from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s index b_2,b b_2 5 NULL 1000 Using where; Using index
......
......@@ -1009,14 +1009,14 @@ s CREATE TABLE `s` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join s.a,t.a from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s ALL NULL NULL NULL NULL 1000
......@@ -1030,7 +1030,7 @@ s CREATE TABLE `s` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1038,7 +1038,7 @@ t CREATE TABLE `t` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join s.a,t.a from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s ALL b NULL NULL NULL 1000 Using where
......@@ -1053,7 +1053,7 @@ s CREATE TABLE `s` (
`c` int(11) DEFAULT NULL,
KEY `b` (`b`),
KEY `b_2` (`b`,`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1062,7 +1062,7 @@ t CREATE TABLE `t` (
`c` int(11) DEFAULT NULL,
KEY `b` (`b`),
KEY `b_2` (`b`,`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join s.a,t.a from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s index b,b_2 b_2 10 NULL 1000 Using where; Using index
......@@ -1082,7 +1082,7 @@ s CREATE TABLE `s` (
KEY `b` (`b`),
KEY `b_2` (`b`,`a`),
KEY `b_3` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1092,7 +1092,7 @@ t CREATE TABLE `t` (
KEY `b` (`b`),
KEY `b_2` (`b`,`a`),
KEY `b_3` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join s.a,t.a from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s index b,b_2,b_3 b_2 10 NULL 1000 Using where; Using index
......@@ -1107,7 +1107,7 @@ s CREATE TABLE `s` (
`c` int(11) DEFAULT NULL,
KEY `b` (`b`),
KEY `b_3` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1116,7 +1116,7 @@ t CREATE TABLE `t` (
`c` int(11) DEFAULT NULL,
KEY `b` (`b`),
KEY `b_3` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join s.a,t.a from s,t where s.b = t.b;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s index b,b_3 b_3 5 NULL 1000 Using where; Using index
......
......@@ -1012,21 +1012,21 @@ s CREATE TABLE `s` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table u;
Table Create Table
u CREATE TABLE `u` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join * from s,t,u where s.b = t.b and s.c = t.c;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s ALL NULL NULL NULL NULL 1000
......@@ -1042,7 +1042,7 @@ s CREATE TABLE `s` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1050,7 +1050,7 @@ t CREATE TABLE `t` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table u;
Table Create Table
u CREATE TABLE `u` (
......@@ -1058,7 +1058,7 @@ u CREATE TABLE `u` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `c` (`c`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join * from s,t,u where s.b = t.b and s.c = u.c;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s ALL b NULL NULL NULL 1000 Using where
......@@ -1081,7 +1081,7 @@ s CREATE TABLE `s` (
`c` int(11) DEFAULT NULL,
KEY `b` (`b`),
KEY `b_2` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table t;
Table Create Table
t CREATE TABLE `t` (
......@@ -1090,7 +1090,7 @@ t CREATE TABLE `t` (
`c` int(11) DEFAULT NULL,
KEY `b` (`b`),
KEY `b_2` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table u;
Table Create Table
u CREATE TABLE `u` (
......@@ -1099,7 +1099,7 @@ u CREATE TABLE `u` (
`c` int(11) DEFAULT NULL,
KEY `c` (`c`),
KEY `c_2` (`c`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select straight_join * from s,t,u where s.b = t.b and s.c = u.c;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE s ALL b,b_2 NULL NULL NULL 1000 Using where
......
......@@ -11,7 +11,7 @@ t1 CREATE TABLE `t1` (
`d` int(11) DEFAULT NULL,
PRIMARY KEY (`a`),
KEY `b` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
create index foo on t1(c,d) clustering=yes;
show create table t1;
Table Create Table
......@@ -23,7 +23,7 @@ t1 CREATE TABLE `t1` (
PRIMARY KEY (`a`),
KEY `b` (`b`) `clustering`=yes,
KEY `foo` (`c`,`d`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table t1 drop primary key;
alter table t1 add primary key (a,b,c,d);
alter table t1 add key bar(d,c,b,a) clustering=yes;
......@@ -38,7 +38,7 @@ t1 CREATE TABLE `t1` (
KEY `b` (`b`) `clustering`=yes,
KEY `foo` (`c`,`d`) `clustering`=yes,
KEY `bar` (`d`,`c`,`b`,`a`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 value (1,1,1,1),(2,2,2,2),(3,3,3,3),(4,4,4,4),(32,54,12,56);
explain select * from t1;
id select_type table type possible_keys key key_len ref rows Extra
......
......@@ -486,7 +486,7 @@ SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`latin1_f` char(32) NOT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
SHOW FIELDS FROM t1;
Field Type Null Key Default Extra
latin1_f char(32) NO NULL
......@@ -496,7 +496,7 @@ SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`latin1_f` char(32) CHARACTER SET latin1 COLLATE latin1_bin DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
SHOW FIELDS FROM t1;
Field Type Null Key Default Extra
latin1_f char(32) YES NULL
......@@ -505,7 +505,7 @@ SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`latin1_f` char(32) COLLATE latin1_bin DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1 COLLATE=latin1_bin
) ENGINE=TokuDB DEFAULT CHARSET=latin1 COLLATE=latin1_bin `compression`='tokudb_zlib'
SHOW FIELDS FROM t1;
Field Type Null Key Default Extra
latin1_f char(32) YES NULL
......
......@@ -85,7 +85,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`name` varchar(10) DEFAULT NULL,
`level` smallint(5) unsigned DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=cp1250
) ENGINE=TokuDB DEFAULT CHARSET=cp1250 `compression`='tokudb_zlib'
insert into t1 values ('string',1);
select concat(name,space(level)), concat(name, repeat(' ',level)) from t1;
concat(name,space(level)) concat(name, repeat(' ',level))
......@@ -178,7 +178,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`name` varchar(10) COLLATE cp1250_czech_cs DEFAULT NULL,
`level` smallint(5) unsigned DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=cp1250 COLLATE=cp1250_czech_cs
) ENGINE=TokuDB DEFAULT CHARSET=cp1250 COLLATE=cp1250_czech_cs `compression`='tokudb_zlib'
insert into t1 values ('string',1);
select concat(name,space(level)), concat(name, repeat(' ',level)) from t1;
concat(name,space(level)) concat(name, repeat(' ',level))
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -8,7 +8,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` varchar(100) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
set session transaction isolation level repeatable read;
begin;
select * from foo;
......
......@@ -6,7 +6,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1);
begin;
insert into foo values (2);
......
......@@ -7,7 +7,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1);
begin;
select * from foo;
......
......@@ -7,7 +7,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
begin;
select * from foo;
a
......
......@@ -7,7 +7,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
begin;
select * from foo;
a
......
......@@ -7,7 +7,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
begin;
select * from foo;
a
......
......@@ -7,7 +7,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
begin;
select * from foo;
a
......
......@@ -8,7 +8,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
set session tokudb_load_save_space=0;
set session transaction isolation level repeatable read;
begin;
......
......@@ -8,7 +8,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
set session tokudb_load_save_space=1;
set session transaction isolation level repeatable read;
begin;
......
......@@ -8,7 +8,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` varchar(100) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
set session transaction isolation level repeatable read;
begin;
select * from foo;
......
......@@ -8,7 +8,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` varchar(100) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
set session transaction isolation level repeatable read;
begin;
select * from foo;
......
......@@ -8,7 +8,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` varchar(100) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
set session transaction isolation level repeatable read;
begin;
select * from foo;
......
......@@ -10,14 +10,14 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` varchar(100) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table bar;
Table Create Table
bar CREATE TABLE `bar` (
`a` int(11) NOT NULL DEFAULT '0',
`b` varchar(100) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
set session transaction isolation level repeatable read;
begin;
# should be empty
......
......@@ -10,7 +10,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1,1);
begin;
select * from foo;
......
......@@ -11,7 +11,7 @@ foo CREATE TABLE `foo` (
`c` int(11) DEFAULT NULL,
PRIMARY KEY (`a`),
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1,10,100),(2,20,200),(3,30,300),(4,40,400),(5,50,500),(6,60,600),(7,70,700),(8,80,800),(9,90,900);
begin;
select * from foo;
......
......@@ -11,7 +11,7 @@ foo CREATE TABLE `foo` (
`c` int(11) DEFAULT NULL,
PRIMARY KEY (`a`),
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1,10,100),(2,20,200),(3,30,300),(4,40,400),(5,50,500),(6,60,600),(7,70,700),(8,80,800),(9,90,900);
begin;
select * from foo;
......
......@@ -11,7 +11,7 @@ foo CREATE TABLE `foo` (
`c` int(11) DEFAULT NULL,
PRIMARY KEY (`a`),
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1,10,100),(2,20,200),(3,30,300),(4,40,400),(5,50,500),(6,60,600),(7,70,700),(8,80,800),(9,90,900);
begin;
select * from foo;
......
......@@ -11,7 +11,7 @@ foo CREATE TABLE `foo` (
`c` int(11) DEFAULT NULL,
PRIMARY KEY (`a`),
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1,10,100),(2,20,200),(3,30,300),(4,40,400),(5,50,500),(6,60,600),(7,70,700),(8,80,800),(9,90,900);
begin;
select * from foo;
......
......@@ -11,7 +11,7 @@ foo CREATE TABLE `foo` (
`c` int(11) DEFAULT NULL,
PRIMARY KEY (`a`),
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1,10,100),(2,20,200),(3,30,300),(4,40,400),(5,50,500),(6,60,600),(7,70,700),(8,80,800),(9,90,900);
begin;
select * from foo;
......
......@@ -11,7 +11,7 @@ foo CREATE TABLE `foo` (
`c` int(11) DEFAULT NULL,
PRIMARY KEY (`a`),
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
create table foo_isam (a int, b int, c int) engine=MyISAM;
insert into foo values (1,10,100),(2,20,200),(3,30,300),(4,40,400),(5,50,500),(6,60,600),(7,70,700),(8,80,800),(9,90,900);
begin;
......
......@@ -7,7 +7,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1),(2),(3);
set session transaction isolation level repeatable read;
begin;
......
......@@ -11,7 +11,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
#should read (1,1)
select * from foo;
a b
......
......@@ -7,7 +7,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1),(2),(3);
set session transaction isolation level repeatable read;
begin;
......
......@@ -9,7 +9,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1,1);
set session transaction isolation level repeatable read;
begin;
......
......@@ -10,7 +10,7 @@ foo CREATE TABLE `foo` (
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`),
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (100,100);
begin;
insert into foo values (1,100);
......
......@@ -9,7 +9,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1,100);
select * from foo;
a b
......
......@@ -11,7 +11,7 @@ foo CREATE TABLE `foo` (
`c` int(11) DEFAULT NULL,
PRIMARY KEY (`a`),
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1,10,100),(2,20,200),(3,30,300),(4,40,400),(5,50,500);
create table foo_isam (a int, b int, c int);
# should use key b
......
......@@ -8,7 +8,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` varchar(100) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
set session transaction isolation level repeatable read;
begin;
select * from foo;
......
......@@ -6,7 +6,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values (1),(2),(3);
begin;
insert into foo values (4);
......
......@@ -25,7 +25,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`s1` varbinary(20) DEFAULT NULL,
`s2` varbinary(20) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values (0x41,0x4100),(0x41,0x4120),(0x4100,0x4120);
select hex(s1), hex(s2) from t1;
hex(s1) hex(s2)
......
......@@ -43,7 +43,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` bit(1) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (a bit(64));
insert into t1 values
......@@ -498,7 +498,7 @@ show create table t2;
Table Create Table
t2 CREATE TABLE `t2` (
`a` bit(7) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1, t2;
create table t1 (id1 int(11), b1 bit(1));
create table t2 (id2 int(11), b2 bit(1));
......@@ -701,6 +701,6 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` bit(8) DEFAULT NULL,
KEY `a` (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
End of 5.1 tests
......@@ -26,12 +26,12 @@ Table Create Table
t3 CREATE TABLE `t3` (
`a` mediumtext,
`b` mediumblob
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create TABLE t4;
Table Create Table
t4 CREATE TABLE `t4` (
`c` mediumtext CHARACTER SET utf8 NOT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1,t2,t3,t4;
CREATE TABLE t1 (a char(257) default "hello");
ERROR 42000: Column length too big for column 'a' (max = 255); use BLOB or TEXT instead
......@@ -365,7 +365,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` text,
KEY `a` (`a`(2100))
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
CREATE TABLE t1 (
t1_id bigint(21) NOT NULL auto_increment,
......@@ -672,7 +672,7 @@ t1 CREATE TABLE `t1` (
`e` int(11) DEFAULT NULL,
PRIMARY KEY (`a`,`b`,`c`(255),`d`),
KEY `a` (`a`,`b`,`d`,`e`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
CREATE table t1 (a blob);
insert into t1 values ('b'),('a\0'),('a'),('a '),('aa'),(NULL);
......@@ -751,7 +751,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` text
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values (default);
select * from t1;
a
......
......@@ -204,7 +204,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`da` date DEFAULT '1962-03-03',
`dt` datetime DEFAULT '1962-03-03 00:00:00'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values ();
insert into t1 values ('2007-03-23 13:49:38','2007-03-23 13:49:38');
Warnings:
......@@ -572,7 +572,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`da` date DEFAULT '1962-03-03',
`dt` datetime DEFAULT '1962-03-03 00:00:00'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values ();
insert into t1 values ('2007-03-23 13:49:38','2007-03-23 13:49:38');
Warnings:
......
......@@ -712,14 +712,14 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`d` decimal(5,0) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (d decimal);
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`d` decimal(10,0) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (d decimal(66,0));
ERROR 42000: Too big precision 66 specified for 'd'. Maximum is 65.
......@@ -880,7 +880,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` decimal(10,0) DEFAULT NULL,
`b` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
select round(a,b) as c from t1 order by c;
c
1000
......
......@@ -1628,14 +1628,14 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` enum('','a','b') NOT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (a enum (' ','a','b ') not null default 'b ');
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` enum('','a','b') NOT NULL DEFAULT 'b'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (a enum ('0','1'));
insert into t1 set a='foobar';
......@@ -1660,7 +1660,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` enum('','1','2') NOT NULL DEFAULT ''
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
set names latin1;
CREATE TABLE t1 (
......@@ -1672,7 +1672,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) DEFAULT '1',
`b` enum('value','_value','') NOT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show columns from t1;
Field Type Null Key Default Extra
a int(11) YES 1
......@@ -1701,7 +1701,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` enum('','','') CHARACTER SET utf8 DEFAULT ''
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values (''), (''), ('');
select a from t1 order by a;
a
......@@ -1719,7 +1719,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` enum('','','') DEFAULT ''
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
select a from t1 order by a;
a
......@@ -1753,28 +1753,28 @@ Table Create Table
t1 CREATE TABLE `t1` (
`f1` int(11) DEFAULT NULL,
`f2` enum('') DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1(russian enum('E','F','EF','FE') NOT NULL DEFAULT'E');
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`russian` enum('E','F','EF','FE') NOT NULL DEFAULT 'E'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1(denormal enum('E','F','E,F','F,E') NOT NULL DEFAULT'E');
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`denormal` enum('E','F','E,F','F,E') NOT NULL DEFAULT 'E'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1(russian_deviant enum('E','F','EF','F,E') NOT NULL DEFAULT'E');
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`russian_deviant` enum('E','F','EF','F,E') NOT NULL DEFAULT 'E'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
CREATE TABLE t1 (
id INT AUTO_INCREMENT PRIMARY KEY,
......
......@@ -96,7 +96,7 @@ t2 CREATE TABLE `t2` (
`col2` double(22,5) DEFAULT NULL,
`col3` double DEFAULT NULL,
`col4` double DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1,t2;
create table t1 (a float);
insert into t1 values (1);
......@@ -239,7 +239,7 @@ show create table t3;
Table Create Table
t3 CREATE TABLE `t3` (
`d` double DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1, t2, t3;
create table t1 select 105213674794682365.00 + 0.0 x;
show warnings;
......
......@@ -5,47 +5,47 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` char(10) CHARACTER SET utf8 DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (c national char(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` char(10) CHARACTER SET utf8 DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (c national varchar(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` varchar(10) CHARACTER SET utf8 DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (c nvarchar(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` varchar(10) CHARACTER SET utf8 DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (c nchar varchar(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` varchar(10) CHARACTER SET utf8 DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (c national character varying(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` varchar(10) CHARACTER SET utf8 DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (c nchar varying(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` varchar(10) CHARACTER SET utf8 DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
......@@ -60,7 +60,7 @@ t1 CREATE TABLE `t1` (
`if(0, NULL, 1.2)` decimal(2,1) DEFAULT NULL,
`if(1, 0.22e1, 1.1)` double NOT NULL DEFAULT '0',
`if(1E0, 1.1, 1.2)` decimal(2,1) NOT NULL DEFAULT '0.0'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 select nullif(1.1, 1.1), nullif(1.1, 1.2), nullif(1.1, 0.11e1), nullif(1.0, 1), nullif(1, 1.0), nullif(1, 1.1);
select * from t1;
......@@ -75,7 +75,7 @@ t1 CREATE TABLE `t1` (
`nullif(1.0, 1)` decimal(2,1) DEFAULT NULL,
`nullif(1, 1.0)` int(1) DEFAULT NULL,
`nullif(1, 1.1)` int(1) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (a decimal(4,2));
insert into t1 value (10000), (1.1e10), ("11111"), (100000.1);
......@@ -179,7 +179,7 @@ t1 CREATE TABLE `t1` (
`truncate(-5678.123451,-3)` decimal(4,0) NOT NULL DEFAULT '0',
`abs(-1.1)` decimal(3,1) NOT NULL DEFAULT '0.0',
`-(-1.1)` decimal(2,1) NOT NULL DEFAULT '0.0'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
set session sql_mode='traditional';
select 1e10/0e0;
......@@ -773,7 +773,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`0.5` decimal(2,1) NOT NULL DEFAULT '0.0'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
select round(1.5),round(2.5);
round(1.5) round(2.5)
......@@ -936,14 +936,14 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`sl` decimal(5,5) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (sl decimal(65, 30));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`sl` decimal(65,30) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (
f1 decimal unsigned not null default 17.49,
......@@ -976,7 +976,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`f0` decimal(30,30) unsigned zerofill NOT NULL DEFAULT '0.000000000000000000000000000000',
`f1` decimal(10,0) unsigned zerofill NOT NULL DEFAULT '0000000000'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
drop procedure if exists wg2;
create procedure wg2()
......@@ -1026,7 +1026,7 @@ t1 CREATE TABLE `t1` (
`my_double` double DEFAULT NULL,
`my_varchar` varchar(50) DEFAULT NULL,
`my_decimal` decimal(65,30) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
INSERT INTO t1 SET my_float = 1.175494345e-32,
my_double = 1.175494345e-32,
my_varchar = '1.175494345e-32';
......@@ -1540,7 +1540,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`5.05 / 0.014` decimal(10,6) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
select * from t1;
5.05 / 0.014
360.714286
......
......@@ -5,14 +5,14 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` set('','a','b') NOT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
create table t1 (a set (' ','a','b ') not null default 'b ');
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` set('','a','b') NOT NULL DEFAULT 'b'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
CREATE TABLE t1 ( user varchar(64) NOT NULL default '', path varchar(255) NOT NULL default '', privilege set('select','RESERVED30','RESERVED29','RESERVED28','RESERVED27','RESERVED26', 'RESERVED25','RESERVED24','data.delete','RESERVED22','RESERVED21', 'RESERVED20','data.insert.none','data.insert.approve', 'data.insert.delete','data.insert.move','data.insert.propose', 'data.insert.reject','RESERVED13','RESERVED12','RESERVED11','RESERVED10', 'RESERVED09','data.update','RESERVED07','RESERVED06','RESERVED05', 'RESERVED04','metadata.delete','metadata.put','RESERVED01','RESERVED00') NOT NULL default '', KEY user (user) ) ENGINE=MyISAM CHARSET=utf8;
DROP TABLE t1;
......@@ -22,7 +22,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`s` set('a','A') CHARACTER SET latin1 COLLATE latin1_bin DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values ('a'),('a,A'),('A,a'),('A');
select s from t1 order by s;
s
......@@ -84,5 +84,5 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`f1` set('1','2','3','4','5','6','7','8','9','10','11','12','13','14','15','16','17','18','19','20','21','22','23','24','25','26','27','28','29','30','31','32','33','34','35','36','37','38','39','40','41','42','43','44','45','46','47','48','49','50','51','52','53','54','55','56','57','58','59','60','61','62','63','64','1') DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
......@@ -195,7 +195,7 @@ t1 CREATE TABLE `t1` (
`t1` timestamp NOT NULL DEFAULT '2003-01-01 00:00:00',
`t2` datetime DEFAULT NULL,
`t3` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show columns from t1;
Field Type Null Key Default Extra
t1 timestamp NO 2003-01-01 00:00:00
......@@ -219,7 +219,7 @@ t1 CREATE TABLE `t1` (
`t1` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`t2` datetime DEFAULT NULL,
`t3` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show columns from t1;
Field Type Null Key Default Extra
t1 timestamp NO CURRENT_TIMESTAMP
......@@ -245,7 +245,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`t1` timestamp NOT NULL DEFAULT '2003-01-01 00:00:00' ON UPDATE CURRENT_TIMESTAMP,
`t2` datetime DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show columns from t1;
Field Type Null Key Default Extra
t1 timestamp NO 2003-01-01 00:00:00 on update CURRENT_TIMESTAMP
......@@ -270,7 +270,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`t1` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`t2` datetime DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show columns from t1;
Field Type Null Key Default Extra
t1 timestamp NO CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP
......@@ -296,7 +296,7 @@ t1 CREATE TABLE `t1` (
`t1` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`t2` datetime DEFAULT NULL,
`t3` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show columns from t1;
Field Type Null Key Default Extra
t1 timestamp NO CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP
......@@ -322,7 +322,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`t1` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`t2` datetime DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show columns from t1;
Field Type Null Key Default Extra
t1 timestamp NO CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP
......@@ -377,7 +377,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` timestamp NULL DEFAULT NULL,
`b` timestamp NULL DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values (NULL, NULL);
SET TIMESTAMP=1000000017;
insert into t1 values ();
......@@ -392,7 +392,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`b` timestamp NULL DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values (NULL, NULL);
SET TIMESTAMP=1000000018;
insert into t1 values ();
......@@ -407,7 +407,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` timestamp NULL DEFAULT NULL,
`b` timestamp NULL DEFAULT '2003-01-01 00:00:00'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values (NULL, NULL);
insert into t1 values (DEFAULT, DEFAULT);
select * from t1;
......
......@@ -9,7 +9,7 @@ t1 CREATE TABLE `t1` (
`c` char(3) DEFAULT NULL,
`e` enum('abc','def','ghi') DEFAULT NULL,
`t` text
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table vchar;
Table Create Table
vchar CREATE TABLE `vchar` (
......@@ -400,21 +400,21 @@ Table Create Table
t1 CREATE TABLE `t1` (
`f1` varchar(65500) DEFAULT NULL,
KEY `index1` (`f1`(10))
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table t1 modify f1 varchar(255);
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`f1` varchar(255) DEFAULT NULL,
KEY `index1` (`f1`(10))
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table t1 modify f1 tinytext;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`f1` tinytext,
KEY `index1` (`f1`(10))
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t1;
DROP TABLE IF EXISTS t1;
CREATE TABLE t1(f1 VARCHAR(100) DEFAULT 'test');
......@@ -423,37 +423,6 @@ DROP TABLE IF EXISTS t1;
CREATE TABLE t1(f1 CHAR(100) DEFAULT 'test');
INSERT INTO t1 VALUES(SUBSTR(f1, 1, 3));
DROP TABLE IF EXISTS t1;
drop table if exists t1, t2, t3;
create table t3 (
id int(11),
en varchar(255) character set utf8,
cz varchar(255) character set utf8
);
truncate table t3;
insert into t3 (id, en, cz) values
(1,'en string 1','cz string 1'),
(2,'en string 2','cz string 2'),
(3,'en string 3','cz string 3');
create table t1 (
id int(11),
name_id int(11)
);
insert into t1 (id, name_id) values (1,1), (2,3), (3,3);
create table t2 (id int(11));
insert into t2 (id) values (1), (2), (3);
select t1.*, t2.id, t3.en, t3.cz from t1 left join t2 on t1.id=t2.id
left join t3 on t1.id=t3.id order by t3.id;
Catalog Database Table Table_alias Column Column_alias Type Length Max length Is_null Flags Decimals Charsetnr
def test t1 t1 id id 3 11 1 Y 32768 0 63
def test t1 t1 name_id name_id 3 11 1 Y 32768 0 63
def test t2 t2 id id 3 11 1 Y 32768 0 63
def test t3 t3 en en 253 255 11 Y 0 0 8
def test t3 t3 cz cz 253 255 11 Y 0 0 8
id name_id id en cz
1 1 1 en string 1 cz string 1
2 3 2 en string 2 cz string 2
3 3 3 en string 3 cz string 3
drop table t1, t2, t3;
CREATE TABLE t1 (a CHAR(2));
INSERT INTO t1 VALUES (10), (50), (30), ('1a'), (60), ('t');
SELECT a,(a + 0) FROM t1 ORDER BY a;
......
......@@ -150,48 +150,6 @@ CREATE TABLE t1(f1 CHAR(100) DEFAULT 'test');
INSERT INTO t1 VALUES(SUBSTR(f1, 1, 3));
DROP TABLE IF EXISTS t1;
#
# Bug#14897 "ResultSet.getString("table.column") sometimes doesn't find the
# column"
# Test that after upgrading an old 4.1 VARCHAR column to 5.0 VARCHAR we preserve
# the original column metadata.
#
--disable_warnings
drop table if exists t1, t2, t3;
--enable_warnings
create table t3 (
id int(11),
en varchar(255) character set utf8,
cz varchar(255) character set utf8
);
#remove_file $MYSQLD_DATADIR/test/t3.frm;
copy_file $MYSQL_TEST_DIR/std_data/14897.frm $MYSQLD_DATADIR/test/t3.frm;
truncate table t3;
insert into t3 (id, en, cz) values
(1,'en string 1','cz string 1'),
(2,'en string 2','cz string 2'),
(3,'en string 3','cz string 3');
create table t1 (
id int(11),
name_id int(11)
);
insert into t1 (id, name_id) values (1,1), (2,3), (3,3);
create table t2 (id int(11));
insert into t2 (id) values (1), (2), (3);
# max_length is different for varchar fields in ps-protocol and we can't
# replace a single metadata column, disable PS protocol
--disable_ps_protocol
--enable_metadata
select t1.*, t2.id, t3.en, t3.cz from t1 left join t2 on t1.id=t2.id
left join t3 on t1.id=t3.id order by t3.id;
--disable_metadata
--enable_ps_protocol
drop table t1, t2, t3;
#
# Bug #11927: Warnings shown for CAST( chr as signed) but not (chr + 0)
#
......
......@@ -9,7 +9,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
/*!50100 PARTITION BY HASH (a)
PARTITIONS 2 */
ALTER TABLE foo ADD KEY(b);
......@@ -20,7 +20,7 @@ foo CREATE TABLE `foo` (
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`),
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
/*!50100 PARTITION BY HASH (a)
PARTITIONS 2 */
DROP TABLE foo;
......@@ -7,33 +7,33 @@ Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE foo ALTER COLUMN a SET DEFAULT 100;
SHOW CREATE TABLE foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '100',
`b` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE foo ALTER COLUMN a DROP DEFAULT;
SHOW CREATE TABLE foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) NOT NULL,
`b` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE foo ALTER COLUMN b SET DEFAULT 42;
SHOW CREATE TABLE foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) NOT NULL,
`b` int(11) DEFAULT '42'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE foo ALTER COLUMN b DROP DEFAULT;
SHOW CREATE TABLE foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) NOT NULL,
`b` int(11)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE foo;
......@@ -15,7 +15,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL AUTO_INCREMENT,
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1
) ENGINE=TokuDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo (b) values (11),(21),(32);
select * from foo;
a b
......@@ -31,7 +31,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL AUTO_INCREMENT,
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB AUTO_INCREMENT=1003 DEFAULT CHARSET=latin1
) ENGINE=TokuDB AUTO_INCREMENT=1003 DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table foo auto_increment=10;
insert into foo (b) values (11),(21),(32);
select * from foo;
......@@ -51,7 +51,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL AUTO_INCREMENT,
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB AUTO_INCREMENT=1006 DEFAULT CHARSET=latin1
) ENGINE=TokuDB AUTO_INCREMENT=1006 DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table foo auto_increment=100000, add column c int;
ERROR 42000: Table 'foo' uses an extension that doesn't exist in this XYZ version
alter table foo auto_increment=100000, drop column b;
......
......@@ -33,7 +33,7 @@ foo CREATE TABLE `foo` (
`e` timestamp(4) NOT NULL DEFAULT '0000-00-00 00:00:00.0000',
`f` timestamp(5) NOT NULL DEFAULT '0000-00-00 00:00:00.00000',
`g` timestamp(6) NOT NULL DEFAULT '0000-00-00 00:00:00.000000'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table foo change b b timestamp(1);
alter table foo change b b timestamp(3);
ERROR 42000: Table 'foo' uses an extension that doesn't exist in this MariaDB version
......@@ -86,7 +86,7 @@ foo CREATE TABLE `foo` (
`e` datetime(4) DEFAULT NULL,
`f` datetime(5) DEFAULT NULL,
`g` datetime(6) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table foo change b b datetime(1);
alter table foo change b b datetime(3);
ERROR 42000: Table 'foo' uses an extension that doesn't exist in this MariaDB version
......@@ -136,7 +136,7 @@ foo CREATE TABLE `foo` (
`e` time(4) DEFAULT NULL,
`f` time(5) DEFAULT NULL,
`g` time(6) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table foo change b b time(1);
alter table foo change b b time(3);
ERROR 42000: Table 'foo' uses an extension that doesn't exist in this MariaDB version
......
......@@ -6,14 +6,14 @@ Table Create Table
foo CREATE TABLE `foo` (
`id` int(11) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
CREATE TABLE bar LIKE foo;
SHOW CREATE TABLE bar;
Table Create Table
bar CREATE TABLE `bar` (
`id` int(11) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE foo ADD COLUMN a INT;
SHOW CREATE TABLE foo;
Table Create Table
......@@ -21,7 +21,7 @@ foo CREATE TABLE `foo` (
`id` int(11) NOT NULL,
`a` int(11) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
FLUSH TABLES;
SHOW CREATE TABLE foo;
Table Create Table
......@@ -29,5 +29,5 @@ foo CREATE TABLE `foo` (
`id` int(11) NOT NULL,
`a` int(11) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE foo, bar;
......@@ -4,7 +4,7 @@ SHOW CREATE TABLE s;
Table Create Table
s CREATE TABLE `s` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
SET tokudb_disable_slow_alter=1;
ALTER TABLE s RENAME TO t, ADD COLUMN b INT;
SHOW CREATE TABLE t;
......@@ -12,5 +12,5 @@ Table Create Table
t CREATE TABLE `t` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE t;
......@@ -8,7 +8,7 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
/*!50100 PARTITION BY HASH (a)
PARTITIONS 2 */
ALTER TABLE foo ADD COLUMN c INT;
......@@ -19,7 +19,7 @@ foo CREATE TABLE `foo` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
/*!50100 PARTITION BY HASH (a)
PARTITIONS 2 */
DROP TABLE foo;
......@@ -33,7 +33,7 @@ foo CREATE TABLE `foo` (
`b` varchar(10) DEFAULT NULL,
`c` blob,
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
select * from foo;
a b c
1 bb cccc
......
......@@ -18,7 +18,7 @@ foo CREATE TABLE `foo` (
PRIMARY KEY (`aa`),
KEY `b` (`b`),
KEY `d` (`d`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
select * from foo;
aa b c d e
1 10 cc dddd eeeee
......@@ -40,7 +40,7 @@ foo CREATE TABLE `foo` (
PRIMARY KEY (`aa`),
KEY `b` (`bb`),
KEY `d` (`d`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select bb from foo FORCE INDEX (b) where bb > 5;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE foo index b b 9 NULL 1 Using where; Using index
......@@ -59,7 +59,7 @@ foo CREATE TABLE `foo` (
PRIMARY KEY (`aa`),
KEY `b` (`bb`),
KEY `d` (`dd`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
explain select * from foo where dd > "d";
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE foo index d d 13 NULL 1 Using where; Using index
......
......@@ -63,7 +63,7 @@ foo CREATE TABLE `foo` (
UNIQUE KEY `c` (`c`),
KEY `d` (`d`),
KEY `b` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table foo change column aa aa int NOT NULL;
ERROR 42000: Table 'foo' uses an extension that doesn't exist in this XYZ version
alter table foo change column aa aa varchar(20);
......
......@@ -62,7 +62,7 @@ foo CREATE TABLE `foo` (
UNIQUE KEY `c` (`c`),
KEY `d` (`d`),
KEY `b` (`b`) `clustering`=yes
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table foo_isam;
Table Create Table
foo_isam CREATE TABLE `foo_isam` (
......@@ -80,7 +80,7 @@ foo_isam CREATE TABLE `foo_isam` (
UNIQUE KEY `c` (`c`),
KEY `d` (`d`),
KEY `b` (`b`) `clustering`=yes
) ENGINE=MyISAM DEFAULT CHARSET=latin1
) ENGINE=MyISAM DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table foo change column aa aa int NOT NULL;
alter table foo_isam change column aa aa int NOT NULL;
include/diff_tables.inc [test.foo, test.foo_isam]
......
......@@ -10,7 +10,7 @@ Table Create Table
foo CREATE TABLE `foo` (
`c1` int(11) NOT NULL,
PRIMARY KEY (`c1`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
ALTER TABLE foo compression=tokudb_lzma, add column c2 int not null;
SELECT CREATE_OPTIONS
FROM INFORMATION_SCHEMA.TABLES WHERE (table_name LIKE 'foo');
......
......@@ -12,7 +12,7 @@ foo CREATE TABLE `foo` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `a` (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
begin;
insert into foo values (1,10,100),(2,20,200),(3,30,300);
set session transaction isolation level read uncommitted;
......@@ -35,7 +35,7 @@ foo CREATE TABLE `foo` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `a` (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
begin;
insert into foo values (1,10,100),(2,20,200),(3,30,300);
insert into foo values (100,100,100);
......@@ -56,7 +56,7 @@ foo CREATE TABLE `foo` (
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL,
KEY `a` (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
begin;
insert into foo values (1,10,100),(2,20,200),(3,30,300);
insert into foo values (100,100,100);
......
......@@ -4,7 +4,7 @@ SHOW CREATE TABLE t;
Table Create Table
t CREATE TABLE `t` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
/*!50100 PARTITION BY KEY (a)
(PARTITION part0 ENGINE = TokuDB,
PARTITION part1 ENGINE = TokuDB) */
......
......@@ -6,7 +6,7 @@ t1 CREATE TABLE `t1` (
`c1` int(11) NOT NULL,
`c2` int(11) NOT NULL,
PRIMARY KEY (`c1`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 (c1,c2) values (1,1),(2,2);
alter table t1 compression=tokudb_lzma;
show create table t1;
......
......@@ -8,7 +8,7 @@ Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values(1);
select * from foo;
a
......@@ -20,7 +20,7 @@ Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
select * from foo;
a
1
......@@ -45,7 +45,7 @@ Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
select * from foo;
a
1
......@@ -67,7 +67,7 @@ Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into foo values(1);
select * from foo;
a
......@@ -84,7 +84,7 @@ show create table fooff;
Table Create Table
fooff CREATE TABLE `fooff` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table fooff;
begin;
select * from bar;
......@@ -100,7 +100,7 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`abra` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
select * from foo;
abra
drop table foo;
......
......@@ -26,7 +26,7 @@ foo CREATE TABLE `foo` (
`b` datetime(4) DEFAULT NULL,
`c` datetime(5) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
select * from foo;
a b c
2010-12-10 14:12:09.123451 2010-12-10 14:12:09.1234 2010-12-10 14:12:09.12345
......
......@@ -7,23 +7,23 @@ Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table bar;
Table Create Table
bar CREATE TABLE `bar` (
`a` int(11) DEFAULT NULL,
KEY `a` (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table bar;
Table Create Table
bar CREATE TABLE `bar` (
`a` int(11) DEFAULT NULL,
KEY `a` (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE foo,bar;
......@@ -9,12 +9,12 @@ show create table foo;
Table Create Table
foo CREATE TABLE `foo` (
`b` bigint(20) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table bar;
Table Create Table
bar CREATE TABLE `bar` (
`a` int(11) DEFAULT NULL,
`b` int(11) DEFAULT NULL,
`c` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE foo,bar;
......@@ -10,11 +10,11 @@ foo CREATE TABLE `foo` (
`a` int(11) NOT NULL DEFAULT '0',
`b` int(11) DEFAULT NULL,
PRIMARY KEY (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
show create table bar;
Table Create Table
bar CREATE TABLE `bar` (
`a` bigint(20) DEFAULT NULL,
KEY `a` (`a`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
DROP TABLE foo,bar;
......@@ -8,7 +8,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values (0),(1),(2),(3),(4),(5),(6),(7),(8),(9);
create table t2(a int);
insert into t2 select A.a + 10*(B.a + 10*C.a) from t1 A, t1 B, t1 C;
......
......@@ -9,7 +9,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) DEFAULT NULL
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert into t1 values (0),(1),(2),(3),(4),(5),(6),(7),(8),(9);
create table t2(a int);
insert into t2 select A.a + 10*(B.a + 10*C.a) from t1 A, t1 B, t1 C;
......
......@@ -9,7 +9,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`i` int(11) DEFAULT NULL,
`j` int(11) DEFAULT '0'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table t1 modify i int default '1';
select * from t1;
i j
......@@ -19,7 +19,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`i` int(11) DEFAULT '1',
`j` int(11) DEFAULT '0'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
alter table t1 modify j int default '2', rename t2;
select * from t1;
ERROR 42S02: Table 'test.t1' doesn't exist
......@@ -31,5 +31,5 @@ Table Create Table
t2 CREATE TABLE `t2` (
`i` int(11) DEFAULT '1',
`j` int(11) DEFAULT '2'
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
drop table t2;
......@@ -7,7 +7,7 @@ t1 CREATE TABLE `t1` (
`c` text,
KEY `a` (`a`) `clustering`=yes,
KEY `b` (`b`)
) ENGINE=TokuDB DEFAULT CHARSET=latin1
) ENGINE=TokuDB DEFAULT CHARSET=latin1 `compression`='tokudb_zlib'
insert t1 values (1, 1, 1);
insert t1 select a+1, a+1, a+1 from t1;
insert t1 select a+2, a+2, a+2 from t1;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment