mirror of
https://github.com/MariaDB/server.git
synced 2025-11-12 10:22:39 +03:00
Merge mronstrom@bk-internal.mysql.com:/home/bk/mysql-5.1-new
into zim.(none):/home/mikael/bug16370 mysql-test/r/partition.result: manual merge mysql-test/t/partition.test: manual merge sql/sql_partition.cc: manual merge
This commit is contained in:
@@ -89,3 +89,16 @@ ALTER TABLE t1
|
||||
PARTITION BY KEY(a)
|
||||
(PARTITION p0 ENGINE = NDB, PARTITION p1 ENGINE = NDB);
|
||||
drop table t1;
|
||||
CREATE TABLE t1 (
|
||||
c1 MEDIUMINT NOT NULL AUTO_INCREMENT,
|
||||
c2 TEXT NOT NULL,
|
||||
c3 INT NOT NULL,
|
||||
c4 BIT NOT NULL,
|
||||
c5 FLOAT,
|
||||
c6 VARCHAR(255),
|
||||
c7 TIMESTAMP,
|
||||
PRIMARY KEY(c1,c3))
|
||||
ENGINE=NDB
|
||||
PARTITION BY KEY(c3) PARTITIONS 5;
|
||||
ALTER TABLE t1 COALESCE PARTITION 4;
|
||||
DROP TABLE t1;
|
||||
|
||||
@@ -428,6 +428,54 @@ partition by list (a)
|
||||
alter table t1 rebuild partition;
|
||||
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
|
||||
drop table t1;
|
||||
create table t1 (a int)
|
||||
partition by list (a)
|
||||
(partition p0 values in (5));
|
||||
insert into t1 values (0);
|
||||
ERROR HY000: Table has no partition for value 0
|
||||
drop table t1;
|
||||
create table t1 (a int)
|
||||
partition by range (a) subpartition by hash (a)
|
||||
(partition p0 values less than (100));
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (a) SUBPARTITION BY HASH (a) (PARTITION p0 VALUES LESS THAN (100) )
|
||||
alter table t1 add partition (partition p1 values less than (200)
|
||||
(subpartition subpart21));
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (a) SUBPARTITION BY HASH (a) (PARTITION p0 VALUES LESS THAN (100) (SUBPARTITION p0sp0 ENGINE = MyISAM), PARTITION p1 VALUES LESS THAN (200) (SUBPARTITION subpart21 ENGINE = MyISAM))
|
||||
drop table t1;
|
||||
create table t1 (a int)
|
||||
partition by key (a);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY KEY (a)
|
||||
alter table t1 add partition (partition p1);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY KEY (a) (PARTITION p0 ENGINE = MyISAM, PARTITION p1 ENGINE = MyISAM)
|
||||
drop table t1;
|
||||
create table t1 (a int, b int)
|
||||
partition by range (a)
|
||||
subpartition by hash(a)
|
||||
(partition p0 values less than (0) (subpartition sp0),
|
||||
partition p1 values less than (1));
|
||||
ERROR 42000: Wrong number of subpartitions defined, mismatch with previous setting near ')' at line 5
|
||||
create table t1 (a int, b int)
|
||||
partition by range (a)
|
||||
subpartition by hash(a)
|
||||
(partition p0 values less than (0),
|
||||
partition p1 values less than (1) (subpartition sp0));
|
||||
ERROR 42000: Wrong number of subpartitions defined, mismatch with previous setting near '))' at line 5
|
||||
create table t1 (a int) engine=innodb partition by hash(a) ;
|
||||
show table status like 't1';
|
||||
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
|
||||
|
||||
Reference in New Issue
Block a user