Skip to content
Permalink
Browse files
MDEV-18650: Options deprecated in previous versions - storage_engine
Remove usage of deprecated variable storage_engine. It was deprecated in 5.5 but
it never issued a deprecation warning. Make it issue a warning in 10.5.1.

Replaced with default_storage_engine.
  • Loading branch information
cvicentiu committed Feb 13, 2020
1 parent 415797f commit 45bc757
Show file tree
Hide file tree
Showing 260 changed files with 802 additions and 768 deletions.
@@ -5,7 +5,7 @@ SET @saved_slave_type_conversions = @@slave_type_conversions;
SET GLOBAL SLAVE_TYPE_CONVERSIONS = 'ALL_NON_LOSSY';

--connection master
if (!$engine_type) {let $engine_type=`SELECT @@storage_engine`; let $engine_type2=`SELECT @@storage_engine`;}
if (!$engine_type) {let $engine_type=`SELECT @@default_storage_engine`; let $engine_type2=`SELECT @@default_storage_engine`;}

--disable_warnings
DROP TABLE IF EXISTS t1,t2,t3,t4,t5,t6,t7,t8,t9,t10;
@@ -58,7 +58,7 @@ GRANT USAGE ON test.* TO mysqltest@localhost;
connect (thread1, localhost, mysqltest,,);
connection thread1;
--echo ** Set up table
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
create table t1(eta int(11) not null, tipo int(11), c varchar(255));
insert into t1 values (7,7, "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
insert into t1 values (8,8, "bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb");
@@ -148,7 +148,7 @@ drop table t1;
#connect (thread1, localhost, mysqltest,,);
connection thread1;
--echo ** Set up table
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
create table t1(eta int(11) not null, tipo int(11), c varchar(255));
insert into t1 values (7,7, "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
insert into t1 values (8,8, "bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb");
@@ -237,7 +237,7 @@ drop table t1;
#connect (thread1, localhost, mysqltest,,);
connection thread1;
--echo ** Set up table
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
create table t1 (a int not null, b int not null);
insert into t1 values (1,1),(2,1),(3,1),(4,1);
--echo ** Create ULL 'hello2'
@@ -287,7 +287,7 @@ drop table t1;
#connect (thread1, localhost, mysqltest,,);
connection thread1;
--echo ** Set up table
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
create table t1(eta int(11) not null, tipo int(11), c varchar(255));
insert into t1 values (7,7, "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
insert into t1 values (8,8, "bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb");
@@ -349,7 +349,7 @@ drop table t1;
#connect (thread1, localhost, mysqltest,,);
connection thread1;
--echo ** Set up table
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
create table t1(eta int(11) not null, tipo int(11), c varchar(255));
insert into t1 values (7,7, "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
insert into t1 values (8,8, "bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb");
@@ -420,7 +420,7 @@ drop table t1;
#connect (thread1, localhost, mysqltest,,);
connection thread1;
--echo ** Set up table
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
create table t1(eta int(11) not null, tipo int(11), c varchar(255));
insert into t1 values (7,7, "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
insert into t1 values (8,8, "bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb");
@@ -478,7 +478,7 @@ drop table t1;
#connect (thread1, localhost, mysqltest,,);
connection thread1;
--echo ** Set up table
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
create table t1(eta int(11) not null, tipo int(11), c varchar(255));
insert into t1 values (7,7, "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
insert into t1 values (8,8, "bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb");
@@ -533,7 +533,7 @@ drop table t1;
#connect (thread1, localhost, mysqltest,,);
connection thread1;
--echo ** Set up table
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
create table t1(eta int(11) not null, tipo int(11), c varchar(255));
insert into t1 values (7,7, "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
insert into t1 values (8,8, "bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb");
@@ -8,7 +8,7 @@
# use SHOW FULL COLUMNS instead.
#
# Please surround all CREATE TABLE with --disable_warnings
# and --enable_warnings to be able to set storage_engine
# and --enable_warnings to be able to set default_storage_engine
# without having to check if the hanlder exists.

SET @safe_character_set_server= @@character_set_server;
@@ -1,7 +1,7 @@
SET STORAGE_ENGINE=MyISAM;
SET DEFAULT_STORAGE_ENGINE=MyISAM;
--source include/ctype_pad.inc

SET STORAGE_ENGINE=HEAP;
SET DEFAULT_STORAGE_ENGINE=HEAP;
--source include/ctype_pad.inc

SET STORAGE_ENGINE=Default;
SET DEFAULT_STORAGE_ENGINE=Default;
@@ -132,7 +132,7 @@ drop table t1, t2;
# Bug#25164 create table `a` as select * from `A` hangs
#

set storage_engine=innodb;
set default_storage_engine=innodb;

--disable_warnings
drop table if exists a;
@@ -149,6 +149,6 @@ drop table A;
drop table if exists a;
--enable_warnings

set storage_engine=default;
set default_storage_engine=default;

--echo End of 5.0 tests.
@@ -1,6 +1,6 @@
# Test if the engine does autocommit in LOAD DATA INFILE, or not

eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;

--disable_warnings
drop table if exists t1;
@@ -55,7 +55,7 @@
# Set the SESSION DEFAULT STORAGE ENGINE to a value <> storage engine
# to be tested. This must not affect any CREATE TABLE statement, where
# the storage engine is assigned explicitly,
eval SET SESSION STORAGE_ENGINE = $other_engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $other_engine_type;

#
# Small basic test with ignore
@@ -1457,8 +1457,8 @@ show variables like "innodb_thread_sleep_delay";
# Test varchar
#

let $default=`select @@storage_engine`;
eval set storage_engine=$engine_type;
let $default=`select @@default_storage_engine`;
eval set default_storage_engine=$engine_type;
source include/varchar.inc;

#
@@ -1479,7 +1479,7 @@ create table t1 (v varchar(65530) character set utf8);
show create table t1;
drop table t1;

eval set storage_engine=$default;
eval set default_storage_engine=$default;

# InnoDB specific varchar tests
eval create table t1 (v varchar(16384)) engine=$engine_type;
@@ -2272,25 +2272,25 @@ drop table t1, t2, t3;
# 3) CREATE ... SELECT

connect (a,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (b,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (c,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (d,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (e,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (f,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (g,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (h,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (i,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (j,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connection a;
create table t1(a int not null, b int, primary key(a));
insert into t1 values (1,2),(5,3),(4,2);
@@ -10,8 +10,8 @@ drop table if exists t1,t3;
create table t1(a int);
insert into t1 values (0),(1),(2),(3),(4),(5),(6),(7),(8),(9);

set @tmp=@@storage_engine;
eval set storage_engine=$engine_type;
set @tmp=@@default_storage_engine;
eval set default_storage_engine=$engine_type;

create table t3 (
ID bigint(20) NOT NULL AUTO_INCREMENT,
@@ -27,7 +27,7 @@ create table t3 (
);

show create table t3;
set storage_engine= @tmp;
set default_storage_engine= @tmp;

insert into t3 select
A.a+10*B.a,
@@ -17,7 +17,7 @@

SET global query_cache_type=ON;
SET local query_cache_type=ON;
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;

# Initialise
--disable_warnings
@@ -120,7 +120,7 @@ drop table t3,t2,t1;

# Establish connection1
connect (connection1,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
SET @@autocommit=1;

connection default;
@@ -130,7 +130,7 @@ SHOW VARIABLES LIKE 'have_query_cache';
SET GLOBAL query_cache_size = 204800;
flush status;
SET @@autocommit=1;
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
eval CREATE TABLE t2 (s1 int, s2 varchar(1000), key(s1))$partitions_s1;
INSERT INTO t2 VALUES (1,repeat('a',10)),(2,repeat('a',10)),(3,repeat('a',10)),(4,repeat('a',10));
COMMIT;
@@ -6,7 +6,7 @@

SET global query_cache_type=ON;
SET local query_cache_type=ON;
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;

# Initialise
--disable_warnings
@@ -19,7 +19,7 @@
# main code t/innodb-big.test --> include/read_many_rows.inc
#

eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;

--disable_warnings
DROP TABLE IF EXISTS t1, t2, t3, t4;
@@ -16,7 +16,7 @@
# main code went into include/rowid_order.inc
#

eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;

--disable_warnings
drop table if exists t1, t2, t3,t4;
@@ -145,15 +145,15 @@ connect (a,localhost,root,,);
connect (b,localhost,root,,);
connect (c,localhost,root,,);
connect (d,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (e,localhost,root,,);
connect (f,localhost,root,,);
connect (g,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connect (h,localhost,root,,);
connect (i,localhost,root,,);
connect (j,localhost,root,,);
eval SET SESSION STORAGE_ENGINE = $engine_type;
eval SET SESSION DEFAULT_STORAGE_ENGINE = $engine_type;
connection a;
eval create table t1(a int not null, b int, primary key(a)) engine = $engine_type;
insert into t1 values (1,2),(5,3),(4,2);
@@ -1,5 +1,5 @@
#
set @@storage_engine= Aria;
set @@default_storage_engine= Aria;
#
# mdev-539: fast build of unique/primary indexes for MyISAM/Aria
#
@@ -250,4 +250,4 @@ select * from customer where c_custkey=3;
c_custkey c_name c_address c_nationkey c_phone c_acctbal c_mktsegment c_comment
3 Customer#000000003 MG9kdTD2WBHm 1 11-719-748-3364 7498.12 AUTOMOBILE special packages wake. slyly reg
DROP DATABASE dbt3_s001;
set @@storage_engine= default;
set @@default_storage_engine= default;
@@ -1,7 +1,7 @@

--echo #
set @@storage_engine= Aria;
set @@default_storage_engine= Aria;

--source include/alter_table_mdev539.inc

set @@storage_engine= default;
set @@default_storage_engine= default;
@@ -1,5 +1,5 @@
#
set @@storage_engine= MyISAM;
set @@default_storage_engine= MyISAM;
#
# mdev-539: fast build of unique/primary indexes for MyISAM/Aria
#
@@ -250,4 +250,4 @@ select * from customer where c_custkey=3;
c_custkey c_name c_address c_nationkey c_phone c_acctbal c_mktsegment c_comment
3 Customer#000000003 MG9kdTD2WBHm 1 11-719-748-3364 7498.12 AUTOMOBILE special packages wake. slyly reg
DROP DATABASE dbt3_s001;
set @@storage_engine= default;
set @@default_storage_engine= default;
@@ -1,7 +1,7 @@

--echo #
set @@storage_engine= MyISAM;
set @@default_storage_engine= MyISAM;

--source include/alter_table_mdev539.inc

set @@storage_engine= default;
set @@default_storage_engine= default;
@@ -1,6 +1,6 @@
SET global query_cache_type=ON;
SET local query_cache_type=ON;
SET SESSION STORAGE_ENGINE = InnoDB;
SET SESSION DEFAULT_STORAGE_ENGINE = InnoDB;
drop table if exists t1,t2,t3;
set @save_query_cache_size = @@global.query_cache_size;
set GLOBAL query_cache_size = 1355776;
@@ -132,7 +132,7 @@ id a
1 me
drop table t3,t2,t1;
connect connection1,localhost,root,,;
SET SESSION STORAGE_ENGINE = InnoDB;
SET SESSION DEFAULT_STORAGE_ENGINE = InnoDB;
SET @@autocommit=1;
connection default;
SHOW VARIABLES LIKE 'have_query_cache';
@@ -141,7 +141,7 @@ have_query_cache YES
SET GLOBAL query_cache_size = 204800;
flush status;
SET @@autocommit=1;
SET SESSION STORAGE_ENGINE = InnoDB;
SET SESSION DEFAULT_STORAGE_ENGINE = InnoDB;
CREATE TABLE t2 (s1 int, s2 varchar(1000), key(s1));
INSERT INTO t2 VALUES (1,repeat('a',10)),(2,repeat('a',10)),(3,repeat('a',10)),(4,repeat('a',10));
COMMIT;

0 comments on commit 45bc757

Please sign in to comment.