Commit 75bc483d authored by Aleksey Midenkov's avatar Aleksey Midenkov Committed by Eugene Kosov

Tests: moved concat_execN() to common.inc

parent f79c4469
......@@ -66,6 +66,20 @@ begin
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
delimiter ;~~
let $default_engine= `select default_engine()`;
......
......@@ -3,3 +3,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -309,6 +309,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create or replace table t(
a int
) engine=innodb;
......@@ -578,3 +590,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -60,6 +60,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create procedure test_01(
sys_type varchar(255),
engine varchar(255),
......@@ -184,3 +196,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -60,6 +60,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create table t1(
id int auto_increment primary key)
with system versioning
......@@ -156,3 +168,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -60,6 +60,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
drop table if exists t1;
create function if not exists non_default_engine()
returns varchar(255)
......
......@@ -169,8 +169,6 @@ insert into t values (1);
update t set a=2 where a=1;
alter table t add column b int, algorithm=inplace;
set versioning_alter_history = keep;
drop procedure concat_exec2;
drop procedure concat_exec3;
drop function get_historical_table_name;
drop procedure drop_last_historical;
select * from mysql.vtmd_template;
......@@ -208,3 +206,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -60,6 +60,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create or replace procedure test_01(
sys_type varchar(255),
engine varchar(255),
......@@ -357,3 +369,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -60,6 +60,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create procedure test_01(
sys_type varchar(255),
engine varchar(255),
......@@ -354,3 +366,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -60,6 +60,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create table t1 (x int)
with system versioning
partition by range columns (x) (
......@@ -361,3 +373,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -60,6 +60,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create or replace table t1 (
x int unsigned,
y int unsigned
......@@ -381,3 +393,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -60,6 +60,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create procedure test_01()
begin
declare engine varchar(255) default default_engine();
......@@ -424,3 +436,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -60,6 +60,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create procedure test_01(
sys_type varchar(255),
engine varchar(255),
......@@ -577,3 +589,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
......@@ -60,6 +60,18 @@ select * from tmp;
drop table tmp;
end if;
end~~
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create table t1 (x int) with system versioning engine innodb;
insert into t1 values (1);
select now(6) into @t1;
......@@ -200,3 +212,5 @@ drop procedure innodb_verify_vtq;
drop function default_engine;
drop function sys_commit_ts;
drop function sys_datatype;
drop procedure concat_exec2;
drop procedure concat_exec3;
-- source suite/versioning/common.inc
delimiter ~~;
create procedure concat_exec2(a varchar(255), b varchar(255))
begin
prepare stmt from concat(a, b);
execute stmt;
deallocate prepare stmt;
end~~
create procedure concat_exec3(a varchar(255), b varchar(255), c varchar(255))
begin
prepare stmt from concat(a, b, c);
execute stmt;
deallocate prepare stmt;
end~~
create function get_historical_table_name(table_name_arg varchar(255))
returns varchar(255)
begin
......@@ -27,7 +12,6 @@ create procedure drop_last_historical(table_name_arg varchar(255))
begin
call concat_exec2('drop table ', get_historical_table_name(table_name_arg));
end~~
delimiter ;~~
set versioning_alter_history= survive;
......@@ -108,8 +92,6 @@ alter table t add column b int, algorithm=inplace;
set versioning_alter_history = keep;
drop procedure concat_exec2;
drop procedure concat_exec3;
drop function get_historical_table_name;
drop procedure drop_last_historical;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment