diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-07-01 18:15:00 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-07-01 18:15:00 +0000 |
commit | a2a2e32c02643a0cec111511220227703fda1cd5 (patch) | |
tree | 69cc2b631234c2a8e026b9cd4d72676c61c594df /mysql-test/suite/versioning/t | |
parent | Releasing progress-linux version 1:10.11.8-1~progress7.99u1. (diff) | |
download | mariadb-a2a2e32c02643a0cec111511220227703fda1cd5.tar.xz mariadb-a2a2e32c02643a0cec111511220227703fda1cd5.zip |
Merging upstream version 1:11.4.2.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'mysql-test/suite/versioning/t')
-rw-r--r-- | mysql-test/suite/versioning/t/create.test | 10 | ||||
-rw-r--r-- | mysql-test/suite/versioning/t/cte.test | 6 | ||||
-rw-r--r-- | mysql-test/suite/versioning/t/derived.test | 4 | ||||
-rw-r--r-- | mysql-test/suite/versioning/t/online.test | 2 | ||||
-rw-r--r-- | mysql-test/suite/versioning/t/rpl.test | 23 | ||||
-rw-r--r-- | mysql-test/suite/versioning/t/select.test | 5 | ||||
-rw-r--r-- | mysql-test/suite/versioning/t/update.test | 1 |
7 files changed, 50 insertions, 1 deletions
diff --git a/mysql-test/suite/versioning/t/create.test b/mysql-test/suite/versioning/t/create.test index 46ed8fad..6a0d327f 100644 --- a/mysql-test/suite/versioning/t/create.test +++ b/mysql-test/suite/versioning/t/create.test @@ -3,6 +3,8 @@ --enable_prepare_warnings +select * from information_schema.periods; + --replace_result $default_engine DEFAULT_ENGINE $sys_datatype_expl SYS_DATATYPE NULL '' eval create table t1 ( x1 int unsigned, @@ -13,6 +15,10 @@ eval create table t1 ( --replace_result $default_engine DEFAULT_ENGINE $sys_datatype_expl SYS_DATATYPE show create table t1; +select * from information_schema.periods where table_name = 't1'; +select column_name, is_system_time_period_start, is_system_time_period_end + from information_schema.columns where table_name = 't1'; + --query_vertical select table_catalog,table_schema,table_name,table_type,version,table_rows,data_free,auto_increment,check_time,table_collation,checksum,create_options,table_comment from information_schema.tables where table_name='t1' --query_vertical select table_catalog,table_schema,table_name,column_name,ordinal_position,column_default,character_maximum_length,character_octet_length,character_set_name,collation_name,column_key,extra,column_comment,is_generated,generation_expression from information_schema.columns where table_name='t1' @@ -23,6 +29,10 @@ create or replace table t1 ( --replace_result $default_engine DEFAULT_ENGINE show create table t1; +select * from information_schema.periods where table_name = 't1'; +select column_name, is_system_time_period_start, is_system_time_period_end + from information_schema.columns where table_name = 't1'; + --replace_result $default_engine DEFAULT_ENGINE --error ER_VERS_PERIOD_COLUMNS eval create or replace table t1 ( diff --git a/mysql-test/suite/versioning/t/cte.test b/mysql-test/suite/versioning/t/cte.test index 025e1b23..f57f7d14 100644 --- a/mysql-test/suite/versioning/t/cte.test +++ b/mysql-test/suite/versioning/t/cte.test @@ -5,6 +5,8 @@ if (`SELECT $PS_PROTOCOL != 0`) --source include/have_innodb.inc --source include/default_optimizer_switch.inc +--let $replace_regex_tsltz6= /TIMESTAMP..WITH LOCAL TIME ZONE..'....-..-.. ..:..:..[.]......'/TIMESTAMP\/*WITH LOCAL TIME ZONE*\/'YYYY-MM-DD hh:ss:mm:.uuuuuu'/ + SET @saved_stats_persistent = @@GLOBAL.innodb_stats_persistent; SET GLOBAL innodb_stats_persistent = OFF; @@ -42,6 +44,7 @@ select row_start into @ts_1 from emp where name="jane"; update emp set mgr=30 where name ="john"; +--replace_regex $replace_regex_tsltz6 explain extended with ancestors as ( select e.emp_id, e.name, e.mgr, e.salary from emp as e where name = 'bill' @@ -68,6 +71,7 @@ as ) select * from ancestors; +--replace_regex $replace_regex_tsltz6 eval explain extended $q; eval $q; @@ -86,6 +90,7 @@ as ) select * from ancestors for system_time as of timestamp @ts_1; +--replace_regex $replace_regex_tsltz6 eval explain extended $q; eval $q; @@ -104,6 +109,7 @@ as ) select name from emp where emp_id in (select emp_id from ancestors for system_time as of timestamp @ts_1); +--replace_regex $replace_regex_tsltz6 eval explain extended $q; eval $q; diff --git a/mysql-test/suite/versioning/t/derived.test b/mysql-test/suite/versioning/t/derived.test index 9d96856f..f599ede9 100644 --- a/mysql-test/suite/versioning/t/derived.test +++ b/mysql-test/suite/versioning/t/derived.test @@ -1,5 +1,7 @@ --source include/default_optimizer_switch.inc +--let $replace_regex_tsltz6= /TIMESTAMP..WITH LOCAL TIME ZONE..'....-..-.. ..:..:..[.]......'/TIMESTAMP\/*WITH LOCAL TIME ZONE*\/'YYYY-MM-DD hh:ss:mm:.uuuuuu'/ + create table emp ( emp_id int, @@ -164,6 +166,7 @@ select * from ( select t1.x, t1.y as y1, t2.x as x2, t2.y as y2 from t1 join t2 on t1.x = t2.x) for system_time as of now() as t; +--replace_regex $replace_regex_tsltz6 let $a=`show warnings`; --echo Query A: echo $a; @@ -174,6 +177,7 @@ select * from ( from t1 for system_time as of now() join t2 for system_time as of now() on t1.x = t2.x) as t; +--replace_regex $replace_regex_tsltz6 let $b=`show warnings`; --echo Query B: echo $b; diff --git a/mysql-test/suite/versioning/t/online.test b/mysql-test/suite/versioning/t/online.test index 5932c346..469b0c64 100644 --- a/mysql-test/suite/versioning/t/online.test +++ b/mysql-test/suite/versioning/t/online.test @@ -5,8 +5,8 @@ set system_versioning_alter_history=keep; create or replace table t (a int); ---error ER_ALTER_OPERATION_NOT_SUPPORTED_REASON alter table t add system versioning, lock=none; +alter table t drop system versioning; --error ER_ALTER_OPERATION_NOT_SUPPORTED_REASON alter table t add system versioning, algorithm=inplace; alter table t add system versioning, lock=shared; diff --git a/mysql-test/suite/versioning/t/rpl.test b/mysql-test/suite/versioning/t/rpl.test index c723751a..d804fe03 100644 --- a/mysql-test/suite/versioning/t/rpl.test +++ b/mysql-test/suite/versioning/t/rpl.test @@ -442,5 +442,28 @@ set sql_mode=default; connection master; drop tables t1, t2, t3; + +--echo # +--echo # MDEV-33330 Server crash or assertion failure in +--echo # binlog_get_pending_rows_event +--echo # + +create or replace table t (x int) with system versioning +partition by system_time interval 1 minute auto partitions 3; +insert into t values (1); + +connect (con1,localhost,root,,); +set timestamp= @@timestamp+120; +update t set x= x + 1; +connection default; + +# Cleanup +disconnect con1; +drop table t; + +# +# End of 11.2 tests +# + --source suite/versioning/common_finish.inc --source include/rpl_end.inc diff --git a/mysql-test/suite/versioning/t/select.test b/mysql-test/suite/versioning/t/select.test index 5603d1a3..b9a836f7 100644 --- a/mysql-test/suite/versioning/t/select.test +++ b/mysql-test/suite/versioning/t/select.test @@ -6,6 +6,8 @@ if (`SELECT $PS_PROTOCOL != 0`) --source suite/versioning/common.inc --source include/default_optimizer_switch.inc +--let $replace_regex_tsltz6= /TIMESTAMP..WITH LOCAL TIME ZONE..'....-..-.. ..:..:..[.]......'/TIMESTAMP\/*WITH LOCAL TIME ZONE*\/'YYYY-MM-DD hh:ss:mm:.uuuuuu'/ + SET @saved_stats_persistent = @@GLOBAL.innodb_stats_persistent; SET GLOBAL innodb_stats_persistent = OFF; @@ -98,11 +100,14 @@ delete from t1; delete from t2; #384 +--replace_regex $replace_regex_tsltz6 explain extended select * from (select t1.x as IJ2_x1, t1.y as y1, t2.x as x2, t2.y as y2 from t1 inner join t2 on t1.x = t2.x) for system_time as of timestamp @t0 as t; +--replace_regex $replace_regex_tsltz6 explain extended select * from (select t1.x as LJ2_x1, t1.y as y1, t2.x as x2, t2.y as y2 from t1 left join t2 on t1.x = t2.x) for system_time as of timestamp @t0 as t; #383 +--replace_regex $replace_regex_tsltz6 explain extended select * from (select t1.x as RJ2_x1, t1.y as y1, t2.x as x2, t2.y as y2 from t1 right join t2 on t1.x = t2.x) for system_time as of timestamp @t0 as t; diff --git a/mysql-test/suite/versioning/t/update.test b/mysql-test/suite/versioning/t/update.test index 6930fecc..50bf331b 100644 --- a/mysql-test/suite/versioning/t/update.test +++ b/mysql-test/suite/versioning/t/update.test @@ -257,6 +257,7 @@ drop table t1; --echo # MDEV-21342 Assertion in set_ok_status() upon spatial field error on system-versioned table --echo # create or replace table t1 (f point, key(f)) with system versioning engine=myisam; +insert t1 values (null); --error ER_CANT_CREATE_GEOMETRY_OBJECT update t1 set f = null where f = 'foo'; |