# MDEV-15951 system versioning by trx id doesn't work with partitioning # currently trx_id does not support partitioning by system_time create or replace table t1( i int, row_start bigint unsigned generated always as row start, row_end bigint unsigned generated always as row end, period for system_time(row_start, row_end) ) engine=InnoDB with system versioning partition by system_time ( partition p0 history, partition pn current ); ERROR HY000: `row_start` must be of type TIMESTAMP(6) for system-versioned table `t1` create or replace table t1( i int, row_start bigint unsigned generated always as row start, row_end bigint unsigned generated always as row end, period for system_time(row_start, row_end) ) engine=InnoDB with system versioning; alter table t1 partition by system_time ( partition p0 history, partition pn current ); ERROR HY000: `row_start` must be of type TIMESTAMP(6) for system-versioned table `#sql-temporary` drop table t1; create or replace table t ( a int primary key, row_start bigint unsigned as row start invisible, row_end bigint unsigned as row end invisible, period for system_time(row_start, row_end) ) engine=innodb with system versioning partition by key() ( partition p1, partition p2 ); ERROR HY000: Transaction-precise system versioned tables do not support partitioning by ROW START or ROW END create or replace table t ( a int primary key, row_start bigint unsigned as row start invisible, row_end bigint unsigned as row end invisible, period for system_time(row_start, row_end) ) engine=innodb with system versioning partition by key(a, row_start) ( partition p1, partition p2 ); ERROR HY000: Transaction-precise system versioned tables do not support partitioning by ROW START or ROW END create or replace table t ( a int primary key, row_start bigint unsigned as row start invisible, row_end bigint unsigned as row end invisible, period for system_time(row_start, row_end) ) engine=innodb with system versioning partition by hash(a + row_end * 2) ( partition p1, partition p2 ); ERROR HY000: Transaction-precise system versioned tables do not support partitioning by ROW START or ROW END create or replace table t ( a int primary key, row_start bigint unsigned as row start invisible, row_end bigint unsigned as row end invisible, period for system_time(row_start, row_end) ) engine=innodb with system versioning partition by range columns (a, row_start) ( partition p1 values less than (100, 100) ); ERROR HY000: Transaction-precise system versioned tables do not support partitioning by ROW START or ROW END # # MDEV-18794 Assertion `!m_innodb' failed in ha_partition::cmp_ref upon SELECT from partitioned table # create or replace table t1 (pk int auto_increment, i int, c char(1), primary key (pk), key(i)) engine=innodb with system versioning partition by key() partitions 2; insert into t1 (i, c) values (1, 'a'), (2, 'b'), (null, 'c'), (null, 'b'); alter table t1 drop system versioning; replace into t1 select * from t1; select * from t1 where i > 0 or pk = 1000 limit 1; pk i c 1 1 a drop table t1; # End of 10.3 tests