Skip to content

Commit

Permalink
MDEV-15103 Assertion in ha_partition::part_records() for updating VIEW
Browse files Browse the repository at this point in the history
add a test case
  • Loading branch information
vuvova committed Feb 23, 2018
1 parent 62b5427 commit f685604
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
8 changes: 8 additions & 0 deletions mysql-test/suite/versioning/r/partition.result
Original file line number Diff line number Diff line change
Expand Up @@ -534,6 +534,14 @@ i
explain partitions select * from t1 for system_time all where row_end = @ts;
id select_type table partitions type possible_keys key key_len ref rows Extra
1 SIMPLE t1 p1_p1sp0,p1_p1sp1 # NULL NULL NULL NULL # #
#
# MDEV-15103 Assertion in ha_partition::part_records() for updating VIEW
#
create or replace table t1 (pk int primary key, f int) with system versioning
partition by system_time limit 100 (partition p1 history, partition pn current);
insert into t1 values (1,10), (2,20);
create or replace view v1 as select * from t1;
update v1 set f= 30;
# Test cleanup
drop database test;
create database test;
9 changes: 9 additions & 0 deletions mysql-test/suite/versioning/t/partition.test
Original file line number Diff line number Diff line change
Expand Up @@ -445,6 +445,15 @@ select * from t1 for system_time all where row_end = @ts;
--replace_column 5 # 10 # 11 #
explain partitions select * from t1 for system_time all where row_end = @ts;

--echo #
--echo # MDEV-15103 Assertion in ha_partition::part_records() for updating VIEW
--echo #
create or replace table t1 (pk int primary key, f int) with system versioning
partition by system_time limit 100 (partition p1 history, partition pn current);
insert into t1 values (1,10), (2,20);
create or replace view v1 as select * from t1;
update v1 set f= 30;

--echo # Test cleanup
drop database test;
create database test;

0 comments on commit f685604

Please sign in to comment.