mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
IB, SQL: InnoDB partitioning [closes #118]
* native InnoDB partitioning for BY SYSTEM_TIME partitions.
This commit is contained in:
10
mysql-test/suite/versioning/t/partition.combinations
Normal file
10
mysql-test/suite/versioning/t/partition.combinations
Normal file
@@ -0,0 +1,10 @@
|
||||
[innodb]
|
||||
innodb
|
||||
partition
|
||||
default-storage-engine=innodb
|
||||
|
||||
[myisam]
|
||||
skip-innodb
|
||||
partition
|
||||
default-storage-engine=myisam
|
||||
|
@@ -1,11 +1,7 @@
|
||||
--source include/have_innodb.inc
|
||||
--source include/have_partition.inc
|
||||
|
||||
### check InnoDB versioning and conventional partitioning
|
||||
### check System Versioning and conventional partitioning
|
||||
|
||||
create table t1 (x int)
|
||||
with system versioning
|
||||
engine innodb
|
||||
partition by range columns (x) (
|
||||
partition p0 values less than (100),
|
||||
partition p1 values less than (1000));
|
||||
@@ -78,6 +74,7 @@ alter table t1 add partition (
|
||||
alter table t1 add partition (
|
||||
partition p1 versioning);
|
||||
|
||||
--replace_result InnoDB ${INNODB_OR_MYISAM} MyISAM ${INNODB_OR_MYISAM} "bigint(20) unsigned" ${SYS_TRX_TYPE} timestamp(6) ${SYS_TRX_TYPE}
|
||||
show create table t1;
|
||||
|
||||
--error ER_VERS_WRONG_PARAMS
|
||||
@@ -99,7 +96,6 @@ select * from t1 partition (pn) for system_time all;
|
||||
# rotation by LIMIT
|
||||
create or replace table t1 (x int)
|
||||
with system versioning
|
||||
engine myisam
|
||||
partition by system_time limit 1 (
|
||||
partition p0 versioning,
|
||||
partition p1 versioning,
|
||||
@@ -118,7 +114,6 @@ select * from t1 partition (p1) for system_time all;
|
||||
# rotation by INTERVAL
|
||||
create or replace table t1 (x int)
|
||||
with system versioning
|
||||
engine myisam
|
||||
partition by system_time interval 1 second (
|
||||
partition p0 versioning,
|
||||
partition p1 versioning,
|
||||
@@ -137,7 +132,6 @@ select * from t1 partition (p1) for system_time all;
|
||||
# Subpartitions
|
||||
create or replace table t1 (x int)
|
||||
with system versioning
|
||||
engine myisam
|
||||
partition by system_time limit 1
|
||||
subpartition by key (x)
|
||||
subpartitions 2 (
|
||||
@@ -156,4 +150,3 @@ select * from t1 partition (p1sp0) for system_time all;
|
||||
select * from t1 partition (p1sp1) for system_time all;
|
||||
|
||||
drop table t1;
|
||||
|
||||
|
Reference in New Issue
Block a user