Commit ab89359d authored by Sergei Golubchik's avatar Sergei Golubchik

enable tests that were skipped because of have_xtradb

* some of these tests run just fine with InnoDB:
   -> s/have_xtradb/have_innodb/
* sys_var tests did basic tests for xtradb only variables
   -> remove them, they're useless anyway (sysvar_innodb does it better)
* multi_update had innodb specific tests
   -> move to multi_update_innodb.test
parent b3d6cbc2
......@@ -6,8 +6,8 @@ innodb-cmpmem
innodb-trx
innodb-sys-indexes
#[xtradb]
#innodb
#innodb-cmpmem
#innodb-trx
#innodb-sys-indexes
[xtradb]
innodb
innodb-cmpmem
innodb-trx
innodb-sys-indexes
......@@ -552,7 +552,7 @@ primary key (pk1, pk2)
);
explain select * from t1 where pk1 = 1 and pk2 < 80 and key1=0;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range PRIMARY,key1 PRIMARY 8 NULL 9 Using where
1 SIMPLE t1 range PRIMARY,key1 PRIMARY 8 NULL 10 Using where
select * from t1 where pk1 = 1 and pk2 < 80 and key1=0;
pk1 pk2 key1 key2 pktail1ok pktail2ok pktail3bad pktail4bad pktail5bad pk2copy badkey filler1 filler2
1 10 0 0 0 0 0 0 0 10 0 filler-data-10 filler2
......@@ -597,7 +597,7 @@ id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 index_merge key1,pktail2ok key1,pktail2ok 4,4 NULL 1 Using intersect(key1,pktail2ok); Using where
explain select * from t1 where (pktail2ok=1 and pk1< 50000) or key1=10;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 index_merge PRIMARY,key1,pktail2ok pktail2ok,key1 8,4 NULL 199 Using sort_union(pktail2ok,key1); Using where
1 SIMPLE t1 index_merge PRIMARY,key1,pktail2ok pktail2ok,key1 8,4 NULL 200 Using sort_union(pktail2ok,key1); Using where
explain select * from t1 where pktail3bad=1 and key1=10;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 ref key1,pktail3bad key1 4 const 100 Using where
......@@ -699,8 +699,8 @@ SELECT COUNT(*) FROM
(SELECT * FROM t1 FORCE INDEX(primary,idx)
WHERE a BETWEEN 2 AND 7 OR pk=1000000) AS t;
id select_type table type possible_keys key key_len ref rows Extra
1 PRIMARY <derived2> ALL NULL NULL NULL NULL 6144
2 DERIVED t1 index_merge PRIMARY,idx idx,PRIMARY 5,4 NULL 6144 Using sort_union(idx,PRIMARY); Using where
1 PRIMARY <derived2> ALL NULL NULL NULL NULL 6145
2 DERIVED t1 index_merge PRIMARY,idx idx,PRIMARY 5,4 NULL 6145 Using sort_union(idx,PRIMARY); Using where
SELECT COUNT(*) FROM
(SELECT * FROM t1 FORCE INDEX(primary,idx)
WHERE a BETWEEN 2 AND 7 OR pk=1000000) AS t;
......
......@@ -455,10 +455,10 @@ Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_par
select * from information_schema.views where TABLE_NAME like "v%";
TABLE_CATALOG TABLE_SCHEMA TABLE_NAME VIEW_DEFINITION CHECK_OPTION IS_UPDATABLE DEFINER SECURITY_TYPE CHARACTER_SET_CLIENT COLLATION_CONNECTION ALGORITHM
def test v0 select `information_schema`.`schemata`.`SCHEMA_NAME` AS `c` from `information_schema`.`schemata` NONE NO root@localhost DEFINER latin1 latin1_swedish_ci UNDEFINED
def test v1 select `information_schema`.`tables`.`TABLE_NAME` AS `c` from `information_schema`.`tables` where (`information_schema`.`tables`.`TABLE_NAME` = 'v1') NONE NO root@localhost DEFINER latin1 latin1_swedish_ci UNDEFINED
def test v2 select `information_schema`.`columns`.`COLUMN_NAME` AS `c` from `information_schema`.`columns` where (`information_schema`.`columns`.`TABLE_NAME` = 'v2') NONE NO root@localhost DEFINER latin1 latin1_swedish_ci UNDEFINED
def test v3 select `information_schema`.`character_sets`.`CHARACTER_SET_NAME` AS `c` from `information_schema`.`character_sets` where (`information_schema`.`character_sets`.`CHARACTER_SET_NAME` like 'latin1%') NONE NO root@localhost DEFINER latin1 latin1_swedish_ci UNDEFINED
def test v4 select `information_schema`.`collations`.`COLLATION_NAME` AS `c` from `information_schema`.`collations` where (`information_schema`.`collations`.`COLLATION_NAME` like 'latin1%') NONE NO root@localhost DEFINER latin1 latin1_swedish_ci UNDEFINED
def test v1 select `information_schema`.`tables`.`TABLE_NAME` AS `c` from `information_schema`.`tables` where `information_schema`.`tables`.`TABLE_NAME` = 'v1' NONE NO root@localhost DEFINER latin1 latin1_swedish_ci UNDEFINED
def test v2 select `information_schema`.`columns`.`COLUMN_NAME` AS `c` from `information_schema`.`columns` where `information_schema`.`columns`.`TABLE_NAME` = 'v2' NONE NO root@localhost DEFINER latin1 latin1_swedish_ci UNDEFINED
def test v3 select `information_schema`.`character_sets`.`CHARACTER_SET_NAME` AS `c` from `information_schema`.`character_sets` where `information_schema`.`character_sets`.`CHARACTER_SET_NAME` like 'latin1%' NONE NO root@localhost DEFINER latin1 latin1_swedish_ci UNDEFINED
def test v4 select `information_schema`.`collations`.`COLLATION_NAME` AS `c` from `information_schema`.`collations` where `information_schema`.`collations`.`COLLATION_NAME` like 'latin1%' NONE NO root@localhost DEFINER latin1 latin1_swedish_ci UNDEFINED
drop view v0, v1, v2, v3, v4;
create table t1 (a int);
grant select,update,insert on t1 to mysqltest_1@localhost;
......@@ -1247,7 +1247,6 @@ table_schema='information_schema' and
or column_type = 'varchar(27)')
group by column_type order by num;
column_type group_concat(table_schema, '.', table_name) num
varchar(27) information_schema.COLUMNS 1
varchar(7) information_schema.ROUTINES,information_schema.VIEWS 2
varchar(20) information_schema.ALL_PLUGINS,information_schema.ALL_PLUGINS,information_schema.ALL_PLUGINS,information_schema.FILES,information_schema.FILES,information_schema.PLUGINS,information_schema.PLUGINS,information_schema.PLUGINS,information_schema.PROFILING 9
create table t1(f1 char(1) not null, f2 char(9) not null)
......@@ -2062,7 +2061,7 @@ where (table_schema = "osm") and (table_name = "test");
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE columns ALL NULL TABLE_SCHEMA,TABLE_NAME NULL NULL NULL NULL Using where; Open_frm_only; Scanned 0 databases
Warnings:
Note 1003 select `information_schema`.`columns`.`COLUMN_NAME` AS `column_name` from `information_schema`.`columns` where ((`information_schema`.`columns`.`TABLE_SCHEMA` = 'osm') and (`information_schema`.`columns`.`TABLE_NAME` = 'test'))
Note 1003 select `information_schema`.`columns`.`COLUMN_NAME` AS `column_name` from `information_schema`.`columns` where `information_schema`.`columns`.`TABLE_SCHEMA` = 'osm' and `information_schema`.`columns`.`TABLE_NAME` = 'test'
explain extended
select information_schema.columns.column_name as column_name
from information_schema.columns
......@@ -2070,7 +2069,7 @@ where (information_schema.columns.table_schema = 'osm') and (information_schema.
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE columns ALL NULL TABLE_SCHEMA,TABLE_NAME NULL NULL NULL NULL Using where; Open_frm_only; Scanned 0 databases
Warnings:
Note 1003 select `information_schema`.`columns`.`COLUMN_NAME` AS `column_name` from `information_schema`.`columns` where ((`information_schema`.`columns`.`TABLE_SCHEMA` = 'osm') and (`information_schema`.`columns`.`TABLE_NAME` = 'test'))
Note 1003 select `information_schema`.`columns`.`COLUMN_NAME` AS `column_name` from `information_schema`.`columns` where `information_schema`.`columns`.`TABLE_SCHEMA` = 'osm' and `information_schema`.`columns`.`TABLE_NAME` = 'test'
drop view v1;
#
# Clean-up.
......
......@@ -17,13 +17,17 @@ GEOMETRY_COLUMNS
GLOBAL_STATUS
GLOBAL_VARIABLES
INDEX_STATISTICS
INNODB_CHANGED_PAGES
INNODB_BUFFER_PAGE
INNODB_BUFFER_PAGE_LRU
INNODB_BUFFER_POOL_STATS
INNODB_CMP
INNODB_CMPMEM
INNODB_CMPMEM_RESET
INNODB_CMP_PER_INDEX
INNODB_CMP_RESET
INNODB_LOCKS
INNODB_LOCK_WAITS
INNODB_METRICS
INNODB_MUTEXES
INNODB_SYS_COLUMNS
INNODB_SYS_FIELDS
......@@ -32,6 +36,7 @@ INNODB_SYS_FOREIGN_COLS
INNODB_SYS_INDEXES
INNODB_SYS_TABLES
INNODB_SYS_TABLESTATS
INNODB_SYS_VIRTUAL
INNODB_TABLESPACES_ENCRYPTION
INNODB_TABLESPACES_SCRUBBING
INNODB_TRX
......@@ -91,13 +96,17 @@ GEOMETRY_COLUMNS F_TABLE_SCHEMA
GLOBAL_STATUS VARIABLE_NAME
GLOBAL_VARIABLES VARIABLE_NAME
INDEX_STATISTICS TABLE_SCHEMA
INNODB_CHANGED_PAGES space_id
INNODB_BUFFER_PAGE POOL_ID
INNODB_BUFFER_PAGE_LRU POOL_ID
INNODB_BUFFER_POOL_STATS POOL_ID
INNODB_CMP page_size
INNODB_CMPMEM page_size
INNODB_CMPMEM_RESET page_size
INNODB_CMP_PER_INDEX database_name
INNODB_CMP_RESET page_size
INNODB_LOCKS lock_id
INNODB_LOCK_WAITS requesting_trx_id
INNODB_METRICS NAME
INNODB_MUTEXES NAME
INNODB_SYS_COLUMNS TABLE_ID
INNODB_SYS_FIELDS INDEX_ID
......@@ -106,6 +115,7 @@ INNODB_SYS_FOREIGN_COLS ID
INNODB_SYS_INDEXES INDEX_ID
INNODB_SYS_TABLES TABLE_ID
INNODB_SYS_TABLESTATS TABLE_ID
INNODB_SYS_VIRTUAL TABLE_ID
INNODB_TABLESPACES_ENCRYPTION SPACE
INNODB_TABLESPACES_SCRUBBING SPACE
INNODB_TRX trx_id
......@@ -165,13 +175,17 @@ GEOMETRY_COLUMNS F_TABLE_SCHEMA
GLOBAL_STATUS VARIABLE_NAME
GLOBAL_VARIABLES VARIABLE_NAME
INDEX_STATISTICS TABLE_SCHEMA
INNODB_CHANGED_PAGES space_id
INNODB_BUFFER_PAGE POOL_ID
INNODB_BUFFER_PAGE_LRU POOL_ID
INNODB_BUFFER_POOL_STATS POOL_ID
INNODB_CMP page_size
INNODB_CMPMEM page_size
INNODB_CMPMEM_RESET page_size
INNODB_CMP_PER_INDEX database_name
INNODB_CMP_RESET page_size
INNODB_LOCKS lock_id
INNODB_LOCK_WAITS requesting_trx_id
INNODB_METRICS NAME
INNODB_MUTEXES NAME
INNODB_SYS_COLUMNS TABLE_ID
INNODB_SYS_FIELDS INDEX_ID
......@@ -180,6 +194,7 @@ INNODB_SYS_FOREIGN_COLS ID
INNODB_SYS_INDEXES INDEX_ID
INNODB_SYS_TABLES TABLE_ID
INNODB_SYS_TABLESTATS TABLE_ID
INNODB_SYS_VIRTUAL TABLE_ID
INNODB_TABLESPACES_ENCRYPTION SPACE
INNODB_TABLESPACES_SCRUBBING SPACE
INNODB_TRX trx_id
......@@ -244,13 +259,17 @@ GEOMETRY_COLUMNS information_schema.GEOMETRY_COLUMNS 1
GLOBAL_STATUS information_schema.GLOBAL_STATUS 1
GLOBAL_VARIABLES information_schema.GLOBAL_VARIABLES 1
INDEX_STATISTICS information_schema.INDEX_STATISTICS 1
INNODB_CHANGED_PAGES information_schema.INNODB_CHANGED_PAGES 1
INNODB_BUFFER_PAGE information_schema.INNODB_BUFFER_PAGE 1
INNODB_BUFFER_PAGE_LRU information_schema.INNODB_BUFFER_PAGE_LRU 1
INNODB_BUFFER_POOL_STATS information_schema.INNODB_BUFFER_POOL_STATS 1
INNODB_CMP information_schema.INNODB_CMP 1
INNODB_CMPMEM information_schema.INNODB_CMPMEM 1
INNODB_CMPMEM_RESET information_schema.INNODB_CMPMEM_RESET 1
INNODB_CMP_PER_INDEX information_schema.INNODB_CMP_PER_INDEX 1
INNODB_CMP_RESET information_schema.INNODB_CMP_RESET 1
INNODB_LOCKS information_schema.INNODB_LOCKS 1
INNODB_LOCK_WAITS information_schema.INNODB_LOCK_WAITS 1
INNODB_METRICS information_schema.INNODB_METRICS 1
INNODB_MUTEXES information_schema.INNODB_MUTEXES 1
INNODB_SYS_COLUMNS information_schema.INNODB_SYS_COLUMNS 1
INNODB_SYS_FIELDS information_schema.INNODB_SYS_FIELDS 1
......@@ -259,6 +278,7 @@ INNODB_SYS_FOREIGN_COLS information_schema.INNODB_SYS_FOREIGN_COLS 1
INNODB_SYS_INDEXES information_schema.INNODB_SYS_INDEXES 1
INNODB_SYS_TABLES information_schema.INNODB_SYS_TABLES 1
INNODB_SYS_TABLESTATS information_schema.INNODB_SYS_TABLESTATS 1
INNODB_SYS_VIRTUAL information_schema.INNODB_SYS_VIRTUAL 1
INNODB_TABLESPACES_ENCRYPTION information_schema.INNODB_TABLESPACES_ENCRYPTION 1
INNODB_TABLESPACES_SCRUBBING information_schema.INNODB_TABLESPACES_SCRUBBING 1
INNODB_TRX information_schema.INNODB_TRX 1
......@@ -308,13 +328,17 @@ Database: information_schema
| GLOBAL_STATUS |
| GLOBAL_VARIABLES |
| INDEX_STATISTICS |
| INNODB_CHANGED_PAGES |
| INNODB_BUFFER_PAGE |
| INNODB_BUFFER_PAGE_LRU |
| INNODB_BUFFER_POOL_STATS |
| INNODB_CMP |
| INNODB_CMPMEM |
| INNODB_CMPMEM_RESET |
| INNODB_CMP_PER_INDEX |
| INNODB_CMP_RESET |
| INNODB_LOCKS |
| INNODB_LOCK_WAITS |
| INNODB_METRICS |
| INNODB_MUTEXES |
| INNODB_SYS_COLUMNS |
| INNODB_SYS_FIELDS |
......@@ -323,6 +347,7 @@ Database: information_schema
| INNODB_SYS_INDEXES |
| INNODB_SYS_TABLES |
| INNODB_SYS_TABLESTATS |
| INNODB_SYS_VIRTUAL |
| INNODB_TABLESPACES_ENCRYPTION |
| INNODB_TABLESPACES_SCRUBBING |
| INNODB_TRX |
......@@ -372,13 +397,17 @@ Database: INFORMATION_SCHEMA
| GLOBAL_STATUS |
| GLOBAL_VARIABLES |
| INDEX_STATISTICS |
| INNODB_CHANGED_PAGES |
| INNODB_BUFFER_PAGE |
| INNODB_BUFFER_PAGE_LRU |
| INNODB_BUFFER_POOL_STATS |
| INNODB_CMP |
| INNODB_CMPMEM |
| INNODB_CMPMEM_RESET |
| INNODB_CMP_PER_INDEX |
| INNODB_CMP_RESET |
| INNODB_LOCKS |
| INNODB_LOCK_WAITS |
| INNODB_METRICS |
| INNODB_MUTEXES |
| INNODB_SYS_COLUMNS |
| INNODB_SYS_FIELDS |
......@@ -387,6 +416,7 @@ Database: INFORMATION_SCHEMA
| INNODB_SYS_INDEXES |
| INNODB_SYS_TABLES |
| INNODB_SYS_TABLESTATS |
| INNODB_SYS_VIRTUAL |
| INNODB_TABLESPACES_ENCRYPTION |
| INNODB_TABLESPACES_SCRUBBING |
| INNODB_TRX |
......@@ -423,5 +453,5 @@ Wildcard: inf_rmation_schema
| information_schema |
SELECT table_schema, count(*) FROM information_schema.TABLES WHERE table_schema IN ('mysql', 'INFORMATION_SCHEMA', 'test', 'mysqltest') GROUP BY TABLE_SCHEMA;
table_schema count(*)
information_schema 59
information_schema 64
mysql 30
CALL mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT.");
drop table if exists t1,t2,t3;
drop database if exists mysqltest;
drop view if exists v1;
revoke all privileges on mysqltest.t1 from mysqltest_1@localhost;
revoke all privileges on mysqltest.* from mysqltest_1@localhost;
delete from mysql.user where user=_binary'mysqltest_1';
create table t1(id1 int not null auto_increment primary key, t char(12));
create table t2(id2 int not null, t char(12));
create table t3(id3 int not null, t char(12), index(id3));
......@@ -452,44 +446,11 @@ ERROR HY000: Table 't1' is specified twice, both as a target for 'UPDATE' and as
delete t1 from t1,t2 where t1.col1 < (select max(col1) from t1) and t1.col1 = t2.col1;
ERROR HY000: Table 't1' is specified twice, both as a target for 'DELETE' and as a separate source for data
drop table t1,t2;
create table t1 (
aclid bigint not null primary key,
status tinyint(1) not null
) engine = innodb;
create table t2 (
refid bigint not null primary key,
aclid bigint, index idx_acl(aclid)
) engine = innodb;
insert into t2 values(1,null);
delete t2, t1 from t2 left join t1 on (t2.aclid=t1.aclid) where t2.refid='1';
drop table t1, t2;
create table t1(a int);
create table t2(a int);
delete from t1,t2 using t1,t2 where t1.a=(select a from t1);
ERROR HY000: Table 't1' is specified twice, both as a target for 'DELETE' and as a separate source for data
drop table t1, t2;
create table t1 ( c char(8) not null ) engine=innodb;
insert into t1 values ('0'),('1'),('2'),('3'),('4'),('5'),('6'),('7'),('8'),('9');
insert into t1 values ('A'),('B'),('C'),('D'),('E'),('F');
alter table t1 add b char(8) not null;
alter table t1 add a char(8) not null;
alter table t1 add primary key (a,b,c);
update t1 set a=c, b=c;
create table t2 like t1;
insert into t2 select * from t1;
delete t1,t2 from t2,t1 where t1.a<'B' and t2.b=t1.b;
drop table t1,t2;
create table t1 ( c char(8) not null ) engine=innodb;
insert into t1 values ('0'),('1'),('2'),('3'),('4'),('5'),('6'),('7'),('8'),('9');
insert into t1 values ('A'),('B'),('C'),('D'),('E'),('F');
alter table t1 add b char(8) not null;
alter table t1 add a char(8) not null;
alter table t1 add primary key (a,b,c);
update t1 set a=c, b=c;
create table t2 like t1;
insert into t2 select * from t1;
delete t1,t2 from t2,t1 where t1.a<'B' and t2.b=t1.b;
drop table t1,t2;
create table t1 (a int, b int);
insert into t1 values (1, 2), (2, 3), (3, 4);
create table t2 (a int);
......@@ -646,7 +607,6 @@ master-bin.000001 # Update_rows_v1 # # table_id: # flags: STMT_END_F
master-bin.000001 # Query # # COMMIT
drop table t1, t2;
set @@session.binlog_format= @sav_binlog_format;
drop table if exists t1, t2, t3;
CREATE TABLE t1 (a int, PRIMARY KEY (a));
CREATE TABLE t2 (a int, PRIMARY KEY (a));
CREATE TABLE t3 (a int, PRIMARY KEY (a)) ENGINE=MyISAM;
......@@ -1040,57 +1000,3 @@ deallocate prepare stmt1;
drop view v3,v2,v1;
drop table t1,t2,t3;
end of 5.5 tests
# Bug mdev-5970
# Bug#13256831 - ERROR 1032 (HY000): CAN'T FIND RECORD
CREATE TABLE t1 (f1 INT PRIMARY KEY, f2 INT) ENGINE=InnoDB;
CREATE TABLE t2 (f1 INT PRIMARY KEY, f2 INT) ENGINE=InnoDB;
INSERT INTO t1 VALUES (5, 7);
INSERT INTO t2 VALUES (6, 97);
CREATE ALGORITHM = MERGE VIEW v1 AS
SELECT a2.f1 AS f1, a2.f2 AS f2
FROM t1 AS a1 JOIN t2 AS a2 ON a1.f2 > a2.f1
WITH LOCAL CHECK OPTION;
SELECT * FROM v1;
f1 f2
6 97
UPDATE v1 SET f1 = 1;
SELECT * FROM v1;
f1 f2
1 97
DROP TABLE t1, t2;
DROP VIEW v1;
#
# MDEV-5973: MySQL Bug#11757486:49539: NON-DESCRIPTIVE ERR (ERROR 0
# FROM STORAGE ENGINE) WITH MULTI-TABLE UPDATE
#
CREATE TABLE table_11757486 (field1 tinyint) ENGINE=INNODB;
INSERT INTO table_11757486 VALUES (0),(0);
SET SESSION SQL_MODE='STRICT_ALL_TABLES';
UPDATE IGNORE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
Warnings:
Warning 1264 Out of range value for column 'field1' at row 1
Warning 1264 Out of range value for column 'field1' at row 2
UPDATE IGNORE table_11757486 SET field1=128;
Warnings:
Warning 1264 Out of range value for column 'field1' at row 1
Warning 1264 Out of range value for column 'field1' at row 2
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. UPDATE IGNORE is unsafe because the order in which rows are updated determines which (if any) rows are ignored. This order cannot be predicted and may differ on master and the slave.
UPDATE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
ERROR 22003: Out of range value for column 'field1' at row 1
UPDATE table_11757486 SET field1=128;
ERROR 22003: Out of range value for column 'field1' at row 1
SET SESSION SQL_MODE='';
UPDATE IGNORE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
Warnings:
Warning 1264 Out of range value for column 'field1' at row 1
Warning 1264 Out of range value for column 'field1' at row 2
UPDATE IGNORE table_11757486 SET field1=128;
Warnings:
Warning 1264 Out of range value for column 'field1' at row 1
Warning 1264 Out of range value for column 'field1' at row 2
Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. UPDATE IGNORE is unsafe because the order in which rows are updated determines which (if any) rows are ignored. This order cannot be predicted and may differ on master and the slave.
DROP TABLE table_11757486;
SET SESSION SQL_MODE=default;
end of 10.0 tests
......@@ -67,3 +67,87 @@ SELECT * FROM t2;
col_int_key pk_1 pk_2 col_int
1 2 3 4
DROP TABLE t1,t2;
# Bug mdev-5970
# Bug#13256831 - ERROR 1032 (HY000): CAN'T FIND RECORD
CREATE TABLE t1 (f1 INT PRIMARY KEY, f2 INT) ENGINE=InnoDB;
CREATE TABLE t2 (f1 INT PRIMARY KEY, f2 INT) ENGINE=InnoDB;
INSERT INTO t1 VALUES (5, 7);
INSERT INTO t2 VALUES (6, 97);
CREATE ALGORITHM = MERGE VIEW v1 AS
SELECT a2.f1 AS f1, a2.f2 AS f2
FROM t1 AS a1 JOIN t2 AS a2 ON a1.f2 > a2.f1
WITH LOCAL CHECK OPTION;
SELECT * FROM v1;
f1 f2
6 97
UPDATE v1 SET f1 = 1;
SELECT * FROM v1;
f1 f2
1 97
DROP TABLE t1, t2;
DROP VIEW v1;
#
# MDEV-5973: MySQL Bug#11757486:49539: NON-DESCRIPTIVE ERR (ERROR 0
# FROM STORAGE ENGINE) WITH MULTI-TABLE UPDATE
#
CREATE TABLE table_11757486 (field1 tinyint) ENGINE=INNODB;
INSERT INTO table_11757486 VALUES (0),(0);
SET SESSION SQL_MODE='STRICT_ALL_TABLES';
UPDATE IGNORE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
Warnings:
Warning 1264 Out of range value for column 'field1' at row 1
Warning 1264 Out of range value for column 'field1' at row 2
UPDATE IGNORE table_11757486 SET field1=128;
Warnings:
Warning 1264 Out of range value for column 'field1' at row 1
Warning 1264 Out of range value for column 'field1' at row 2
UPDATE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
ERROR 22003: Out of range value for column 'field1' at row 1
UPDATE table_11757486 SET field1=128;
ERROR 22003: Out of range value for column 'field1' at row 1
SET SESSION SQL_MODE='';
UPDATE IGNORE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
Warnings:
Warning 1264 Out of range value for column 'field1' at row 1
Warning 1264 Out of range value for column 'field1' at row 2
UPDATE IGNORE table_11757486 SET field1=128;
Warnings:
Warning 1264 Out of range value for column 'field1' at row 1
Warning 1264 Out of range value for column 'field1' at row 2
DROP TABLE table_11757486;
SET SESSION SQL_MODE=default;
create table t1 (
aclid bigint not null primary key,
status tinyint(1) not null
) engine = innodb;
create table t2 (
refid bigint not null primary key,
aclid bigint, index idx_acl(aclid)
) engine = innodb;
insert into t2 values(1,null);
delete t2, t1 from t2 left join t1 on (t2.aclid=t1.aclid) where t2.refid='1';
drop table t1, t2;
create table t1 ( c char(8) not null ) engine=innodb;
insert into t1 values ('0'),('1'),('2'),('3'),('4'),('5'),('6'),('7'),('8'),('9');
insert into t1 values ('A'),('B'),('C'),('D'),('E'),('F');
alter table t1 add b char(8) not null;
alter table t1 add a char(8) not null;
alter table t1 add primary key (a,b,c);
update t1 set a=c, b=c;
create table t2 like t1;
insert into t2 select * from t1;
delete t1,t2 from t2,t1 where t1.a<'B' and t2.b=t1.b;
drop table t1,t2;
create table t1 ( c char(8) not null ) engine=innodb;
insert into t1 values ('0'),('1'),('2'),('3'),('4'),('5'),('6'),('7'),('8'),('9');
insert into t1 values ('A'),('B'),('C'),('D'),('E'),('F');
alter table t1 add b char(8) not null;
alter table t1 add a char(8) not null;
alter table t1 add primary key (a,b,c);
update t1 set a=c, b=c;
create table t2 like t1;
insert into t2 select * from t1;
delete t1,t2 from t2,t1 where t1.a<'B' and t2.b=t1.b;
drop table t1,t2;
......@@ -313,7 +313,7 @@ from t1 A, t1 B, t1 C;
explain
select count(length(a) + length(filler)) from t2 force index (a) where a>='a-1000-a' and a <'a-1001-a';
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t2 range a a 9 NULL 99 Using index condition; Rowid-ordered scan
1 SIMPLE t2 range a a 9 NULL 100 Using index condition; Rowid-ordered scan
select count(length(a) + length(filler)) from t2 force index (a) where a>='a-1000-a' and a <'a-1001-a';
count(length(a) + length(filler))
100
......
-- source include/not_embedded.inc
-- source include/have_xtradb.inc
-- source include/have_innodb.inc
-- source filekeys_plugin.inc
--eval call mtr.add_suppression("$SEARCH_PATTERN")
......
-- source include/have_xtradb.inc
-- source include/have_innodb.inc
-- source filekeys_plugin.inc
create table t1(c1 bigint not null, b char(200)) engine=innodb encrypted=yes encryption_key_id=1;
......
......@@ -7,9 +7,7 @@ source include/have_sequence.inc;
# Row binlog format to fill binlog cache faster
source include/have_binlog_format_row.inc;
# Nothing XtraDB specific in this test, it just needs *some* transactional
# engine. But there's no need to run it twice for InnoDB and XtraDB.
source include/have_xtradb.inc;
source include/have_innodb.inc;
#
# MyISAM messing around with IO_CACHE::file
......
......@@ -68,7 +68,7 @@ def information_schema COLUMNS COLUMN_NAME 4 NO varchar 64 192 NULL NULL NULL u
def information_schema COLUMNS COLUMN_TYPE 16 NO longtext 4294967295 4294967295 NULL NULL NULL utf8 utf8_general_ci longtext select
def information_schema COLUMNS DATA_TYPE 8 NO varchar 64 192 NULL NULL NULL utf8 utf8_general_ci varchar(64) select
def information_schema COLUMNS DATETIME_PRECISION 13 NULL YES bigint NULL NULL 20 0 NULL NULL NULL bigint(21) unsigned select
def information_schema COLUMNS EXTRA 18 NO varchar 27 81 NULL NULL NULL utf8 utf8_general_ci varchar(27) select
def information_schema COLUMNS EXTRA 18 NO varchar 30 90 NULL NULL NULL utf8 utf8_general_ci varchar(30) select
def information_schema COLUMNS IS_NULLABLE 7 NO varchar 3 9 NULL NULL NULL utf8 utf8_general_ci varchar(3) select
def information_schema COLUMNS NUMERIC_PRECISION 11 NULL YES bigint NULL NULL 20 0 NULL NULL NULL bigint(21) unsigned select
def information_schema COLUMNS NUMERIC_SCALE 12 NULL YES bigint NULL NULL 20 0 NULL NULL NULL bigint(21) unsigned select
......@@ -128,7 +128,7 @@ def information_schema FILES ENGINE 10 NO varchar 64 192 NULL NULL NULL utf8 ut
def information_schema FILES EXTENT_SIZE 16 0 NO bigint NULL NULL 19 0 NULL NULL NULL bigint(4) select
def information_schema FILES EXTRA 38 NULL YES varchar 255 765 NULL NULL NULL utf8 utf8_general_ci varchar(255) select
def information_schema FILES FILE_ID 1 0 NO bigint NULL NULL 19 0 NULL NULL NULL bigint(4) select
def information_schema FILES FILE_NAME 2 NULL YES varchar 64 192 NULL NULL NULL utf8 utf8_general_ci varchar(64) select
def information_schema FILES FILE_NAME 2 NULL YES varchar 512 1536 NULL NULL NULL utf8 utf8_general_ci varchar(512) select
def information_schema FILES FILE_TYPE 3 NO varchar 20 60 NULL NULL NULL utf8 utf8_general_ci varchar(20) select
def information_schema FILES FREE_EXTENTS 14 NULL YES bigint NULL NULL 19 0 NULL NULL NULL bigint(4) select
def information_schema FILES FULLTEXT_KEYS 11 NULL YES varchar 64 192 NULL NULL NULL utf8 utf8_general_ci varchar(64) select
......@@ -602,7 +602,7 @@ NULL information_schema COLUMNS DATETIME_PRECISION bigint NULL NULL NULL NULL bi
3.0000 information_schema COLUMNS COLLATION_NAME varchar 32 96 utf8 utf8_general_ci varchar(32)
1.0000 information_schema COLUMNS COLUMN_TYPE longtext 4294967295 4294967295 utf8 utf8_general_ci longtext
3.0000 information_schema COLUMNS COLUMN_KEY varchar 3 9 utf8 utf8_general_ci varchar(3)
3.0000 information_schema COLUMNS EXTRA varchar 27 81 utf8 utf8_general_ci varchar(27)
3.0000 information_schema COLUMNS EXTRA varchar 30 90 utf8 utf8_general_ci varchar(30)
3.0000 information_schema COLUMNS PRIVILEGES varchar 80 240 utf8 utf8_general_ci varchar(80)
3.0000 information_schema COLUMNS COLUMN_COMMENT varchar 1024 3072 utf8 utf8_general_ci varchar(1024)
3.0000 information_schema COLUMN_PRIVILEGES GRANTEE varchar 190 570 utf8 utf8_general_ci varchar(190)
......@@ -644,7 +644,7 @@ NULL information_schema EVENTS ORIGINATOR bigint NULL NULL NULL NULL bigint(10)
3.0000 information_schema EVENTS COLLATION_CONNECTION varchar 32 96 utf8 utf8_general_ci varchar(32)
3.0000 information_schema EVENTS DATABASE_COLLATION varchar 32 96 utf8 utf8_general_ci varchar(32)
NULL information_schema FILES FILE_ID bigint NULL NULL NULL NULL bigint(4)
3.0000 information_schema FILES FILE_NAME varchar 64 192 utf8 utf8_general_ci varchar(64)
3.0000 information_schema FILES FILE_NAME varchar 512 1536 utf8 utf8_general_ci varchar(512)
3.0000 information_schema FILES FILE_TYPE varchar 20 60 utf8 utf8_general_ci varchar(20)
3.0000 information_schema FILES TABLESPACE_NAME varchar 64 192 utf8 utf8_general_ci varchar(64)
3.0000 information_schema FILES TABLE_CATALOG varchar 64 192 utf8 utf8_general_ci varchar(64)
......
......@@ -16,7 +16,7 @@
#
--source include/not_embedded.inc
--source include/have_xtradb.inc
--source include/have_innodb.inc
let $my_where = WHERE table_schema = 'information_schema'
AND table_name <> 'profiling' AND table_name not like 'innodb_%';
......
SET @start_value = @@GLOBAL.innodb_cleaner_eviction_factor;
SELECT @@GLOBAL.innodb_cleaner_eviction_factor;
@@GLOBAL.innodb_cleaner_eviction_factor
0
SELECT @@SESSION.innodb_cleaner_eviction_factor;
ERROR HY000: Variable 'innodb_cleaner_eviction_factor' is a GLOBAL variable
SET GLOBAL innodb_cleaner_eviction_factor='OFF';
SELECT @@GLOBAL.innodb_cleaner_eviction_factor;
@@GLOBAL.innodb_cleaner_eviction_factor
0
SET GLOBAL innodb_cleaner_eviction_factor='ON';
SELECT @@GLOBAL.innodb_cleaner_eviction_factor;
@@GLOBAL.innodb_cleaner_eviction_factor
1
SET GLOBAL innodb_cleaner_eviction_factor=0;
SELECT @@GLOBAL.innodb_cleaner_eviction_factor;
@@GLOBAL.innodb_cleaner_eviction_factor
0
SET GLOBAL innodb_cleaner_eviction_factor=1;
SELECT @@GLOBAL.innodb_cleaner_eviction_factor;
@@GLOBAL.innodb_cleaner_eviction_factor
1
SET GLOBAL innodb_cleaner_eviction_factor=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_eviction_factor'
SET GLOBAL innodb_cleaner_eviction_factor=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_eviction_factor'
SET GLOBAL innodb_cleaner_eviction_factor=2;
ERROR 42000: Variable 'innodb_cleaner_eviction_factor' can't be set to the value of '2'
SET GLOBAL innodb_cleaner_eviction_factor='foo';
ERROR 42000: Variable 'innodb_cleaner_eviction_factor' can't be set to the value of 'foo'
SET GLOBAL innodb_cleaner_eviction_factor = @start_value;
SET @start_value = @@GLOBAL.innodb_cleaner_flush_chunk_size;
SELECT @@GLOBAL.innodb_cleaner_flush_chunk_size;
@@GLOBAL.innodb_cleaner_flush_chunk_size
100
SELECT @@SESSION.innodb_cleaner_flush_chunk_size;
ERROR HY000: Variable 'innodb_cleaner_flush_chunk_size' is a GLOBAL variable
SET GLOBAL innodb_cleaner_flush_chunk_size=1;
SELECT @@GLOBAL.innodb_cleaner_flush_chunk_size;
@@GLOBAL.innodb_cleaner_flush_chunk_size
1
SET GLOBAL innodb_cleaner_flush_chunk_size=1000;
SELECT @@GLOBAL.innodb_cleaner_flush_chunk_size;
@@GLOBAL.innodb_cleaner_flush_chunk_size
1000
SET GLOBAL innodb_cleaner_flush_chunk_size=4294967295;
SELECT @@GLOBAL.innodb_cleaner_flush_chunk_size;
@@GLOBAL.innodb_cleaner_flush_chunk_size
4294967295
SET GLOBAL innodb_cleaner_flush_chunk_size=0;
Warnings:
Warning 1292 Truncated incorrect innodb_cleaner_flush_chunk_size value: '0'
SELECT @@GLOBAL.innodb_cleaner_flush_chunk_size;
@@GLOBAL.innodb_cleaner_flush_chunk_size
1
SET GLOBAL innodb_cleaner_flush_chunk_size=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_flush_chunk_size'
SET GLOBAL innodb_cleaner_flush_chunk_size=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_flush_chunk_size'
SET GLOBAL innodb_cleaner_flush_chunk_size='foo';
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_flush_chunk_size'
SET GLOBAL innodb_cleaner_flush_chunk_size = @start_value;
SET @start_value = @@GLOBAL.innodb_cleaner_free_list_lwm;
SELECT @@GLOBAL.innodb_cleaner_free_list_lwm;
@@GLOBAL.innodb_cleaner_free_list_lwm
10
SELECT @@SESSION.innodb_cleaner_free_list_lwm;
ERROR HY000: Variable 'innodb_cleaner_free_list_lwm' is a GLOBAL variable
SET GLOBAL innodb_cleaner_free_list_lwm=0;
SELECT @@GLOBAL.innodb_cleaner_free_list_lwm;
@@GLOBAL.innodb_cleaner_free_list_lwm
0
SET GLOBAL innodb_cleaner_free_list_lwm=1;
SELECT @@GLOBAL.innodb_cleaner_free_list_lwm;
@@GLOBAL.innodb_cleaner_free_list_lwm
1
SET GLOBAL innodb_cleaner_free_list_lwm=99;
SELECT @@GLOBAL.innodb_cleaner_free_list_lwm;
@@GLOBAL.innodb_cleaner_free_list_lwm
99
SET GLOBAL innodb_cleaner_free_list_lwm=100;
SELECT @@GLOBAL.innodb_cleaner_free_list_lwm;
@@GLOBAL.innodb_cleaner_free_list_lwm
100
SET GLOBAL innodb_cleaner_free_list_lwm=101;
Warnings:
Warning 1292 Truncated incorrect innodb_cleaner_free_list_lwm value: '101'
SELECT @@innodb_cleaner_free_list_lwm;
@@innodb_cleaner_free_list_lwm
100
SET GLOBAL innodb_cleaner_free_list_lwm=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_free_list_lwm'
SET GLOBAL innodb_cleaner_free_list_lwm=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_free_list_lwm'
SET GLOBAL innodb_cleaner_free_list_lwm='foo';
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_free_list_lwm'
SET GLOBAL innodb_cleaner_free_list_lwm = @start_value;
SET @start_value = @@GLOBAL.innodb_cleaner_lru_chunk_size;
SELECT @@GLOBAL.innodb_cleaner_lru_chunk_size;
@@GLOBAL.innodb_cleaner_lru_chunk_size
100
SELECT @@SESSION.innodb_cleaner_lru_chunk_size;
ERROR HY000: Variable 'innodb_cleaner_lru_chunk_size' is a GLOBAL variable
SET GLOBAL innodb_cleaner_lru_chunk_size=1;
SELECT @@GLOBAL.innodb_cleaner_lru_chunk_size;
@@GLOBAL.innodb_cleaner_lru_chunk_size
1
SET GLOBAL innodb_cleaner_lru_chunk_size=1000;
SELECT @@GLOBAL.innodb_cleaner_lru_chunk_size;
@@GLOBAL.innodb_cleaner_lru_chunk_size
1000
SET GLOBAL innodb_cleaner_lru_chunk_size=4294967295;
SELECT @@GLOBAL.innodb_cleaner_lru_chunk_size;
@@GLOBAL.innodb_cleaner_lru_chunk_size
4294967295
SET GLOBAL innodb_cleaner_lru_chunk_size=0;
Warnings:
Warning 1292 Truncated incorrect innodb_cleaner_lru_chunk_size value: '0'
SELECT @@GLOBAL.innodb_cleaner_lru_chunk_size;
@@GLOBAL.innodb_cleaner_lru_chunk_size
1
SET GLOBAL innodb_cleaner_lru_chunk_size=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_lru_chunk_size'
SET GLOBAL innodb_cleaner_lru_chunk_size=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_lru_chunk_size'
SET GLOBAL innodb_cleaner_lru_chunk_size='foo';
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_lru_chunk_size'
SET GLOBAL innodb_cleaner_lru_chunk_size = @start_value;
SET @start_value = @@GLOBAL.innodb_cleaner_lsn_age_factor;
SELECT @@GLOBAL.innodb_cleaner_lsn_age_factor;
@@GLOBAL.innodb_cleaner_lsn_age_factor
HIGH_CHECKPOINT
SELECT @@SESSION.innodb_cleaner_lsn_age_factor;
ERROR HY000: Variable 'innodb_cleaner_lsn_age_factor' is a GLOBAL variable
SET GLOBAL innodb_cleaner_lsn_age_factor='legacy';
SELECT @@GLOBAL.innodb_cleaner_lsn_age_factor;
@@GLOBAL.innodb_cleaner_lsn_age_factor
LEGACY
SET GLOBAL innodb_cleaner_lsn_age_factor='high_checkpoint';
SELECT @@GLOBAL.innodb_cleaner_lsn_age_factor;
@@GLOBAL.innodb_cleaner_lsn_age_factor
HIGH_CHECKPOINT
SET GLOBAL innodb_cleaner_lsn_age_factor=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_lsn_age_factor'
SET GLOBAL innodb_cleaner_lsn_age_factor=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_lsn_age_factor'
SET GLOBAL innodb_cleaner_lsn_age_factor='foo';
ERROR 42000: Variable 'innodb_cleaner_lsn_age_factor' can't be set to the value of 'foo'
SET GLOBAL innodb_cleaner_lsn_age_factor = @start_value;
SET @start_value = @@GLOBAL.innodb_cleaner_max_flush_time;
SELECT @@GLOBAL.innodb_cleaner_max_flush_time;
@@GLOBAL.innodb_cleaner_max_flush_time
1000
SELECT @@SESSION.innodb_cleaner_max_flush_time;
ERROR HY000: Variable 'innodb_cleaner_max_flush_time' is a GLOBAL variable
SET GLOBAL innodb_cleaner_max_flush_time=0;
SELECT @@GLOBAL.innodb_cleaner_max_flush_time;
@@GLOBAL.innodb_cleaner_max_flush_time
0
SET GLOBAL innodb_cleaner_max_flush_time=1000;
SELECT @@GLOBAL.innodb_cleaner_max_flush_time;
@@GLOBAL.innodb_cleaner_max_flush_time
1000
SET GLOBAL innodb_cleaner_max_flush_time=4294967295;
SELECT @@GLOBAL.innodb_cleaner_max_flush_time;
@@GLOBAL.innodb_cleaner_max_flush_time
4294967295
SET GLOBAL innodb_cleaner_max_flush_time=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_max_flush_time'
SET GLOBAL innodb_cleaner_max_flush_time=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_max_flush_time'
SET GLOBAL innodb_cleaner_max_flush_time='foo';
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_max_flush_time'
SET GLOBAL innodb_cleaner_max_flush_time = @start_value;
SET @start_value = @@GLOBAL.innodb_cleaner_max_lru_time;
SELECT @@GLOBAL.innodb_cleaner_max_lru_time;
@@GLOBAL.innodb_cleaner_max_lru_time
1000
SELECT @@SESSION.innodb_cleaner_max_lru_time;
ERROR HY000: Variable 'innodb_cleaner_max_lru_time' is a GLOBAL variable
SET GLOBAL innodb_cleaner_max_lru_time=0;
SELECT @@GLOBAL.innodb_cleaner_max_lru_time;
@@GLOBAL.innodb_cleaner_max_lru_time
0
SET GLOBAL innodb_cleaner_max_lru_time=1000;
SELECT @@GLOBAL.innodb_cleaner_max_lru_time;
@@GLOBAL.innodb_cleaner_max_lru_time
1000
SET GLOBAL innodb_cleaner_max_lru_time=4294967295;
SELECT @@GLOBAL.innodb_cleaner_max_lru_time;
@@GLOBAL.innodb_cleaner_max_lru_time
4294967295
SET GLOBAL innodb_cleaner_max_lru_time=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_max_lru_time'
SET GLOBAL innodb_cleaner_max_lru_time=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_max_lru_time'
SET GLOBAL innodb_cleaner_max_lru_time='foo';
ERROR 42000: Incorrect argument type to variable 'innodb_cleaner_max_lru_time'
SET GLOBAL innodb_cleaner_max_lru_time = @start_value;
SET @start_value = @@GLOBAL.innodb_empty_free_list_algorithm;
SELECT @@GLOBAL.innodb_empty_free_list_algorithm;
@@GLOBAL.innodb_empty_free_list_algorithm
BACKOFF
SELECT @@SESSION.innodb_empty_free_list_algorithm;
ERROR HY000: Variable 'innodb_empty_free_list_algorithm' is a GLOBAL variable
SET GLOBAL innodb_empty_free_list_algorithm='legacy';
SELECT @@GLOBAL.innodb_empty_free_list_algorithm;
@@GLOBAL.innodb_empty_free_list_algorithm
LEGACY
SET GLOBAL innodb_empty_free_list_algorithm='backoff';
SELECT @@GLOBAL.innodb_empty_free_list_algorithm;
@@GLOBAL.innodb_empty_free_list_algorithm
BACKOFF
SET GLOBAL innodb_empty_free_list_algorithm=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_empty_free_list_algorithm'
SET GLOBAL innodb_empty_free_list_algorithm=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_empty_free_list_algorithm'
SET GLOBAL innodb_empty_free_list_algorithm=2;
ERROR 42000: Variable 'innodb_empty_free_list_algorithm' can't be set to the value of '2'
SET GLOBAL innodb_empty_free_list_algorithm='foo';
ERROR 42000: Variable 'innodb_empty_free_list_algorithm' can't be set to the value of 'foo'
SET GLOBAL innodb_empty_free_list_algorithm = @start_value;
SET @start_value = @@GLOBAL.innodb_foreground_preflush;
SELECT @@GLOBAL.innodb_foreground_preflush;
@@GLOBAL.innodb_foreground_preflush
EXPONENTIAL_BACKOFF
SELECT @@SESSION.innodb_foreground_preflush;
ERROR HY000: Variable 'innodb_foreground_preflush' is a GLOBAL variable
SET GLOBAL innodb_foreground_preflush='sync_preflush';
SELECT @@GLOBAL.innodb_foreground_preflush;
@@GLOBAL.innodb_foreground_preflush
SYNC_PREFLUSH
SET GLOBAL innodb_foreground_preflush='exponential_backoff';
SELECT @@GLOBAL.innodb_foreground_preflush;
@@GLOBAL.innodb_foreground_preflush
EXPONENTIAL_BACKOFF
SET GLOBAL innodb_foreground_preflush=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_foreground_preflush'
SET GLOBAL innodb_foreground_preflush=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_foreground_preflush'
SET GLOBAL innodb_foreground_preflush=2;
ERROR 42000: Variable 'innodb_foreground_preflush' can't be set to the value of '2'
SET GLOBAL innodb_foreground_preflush='foo';
ERROR 42000: Variable 'innodb_foreground_preflush' can't be set to the value of 'foo'
SET GLOBAL innodb_foreground_preflush = @start_value;
SELECT @@GLOBAL.innodb_log_arch_dir;
@@GLOBAL.innodb_log_arch_dir
./
NULL Expected
SET @@GLOBAL.innodb_log_arch_dir=1;
ERROR HY000: Variable 'innodb_log_arch_dir' is a read only variable
Expected error 'Read only variable'
SELECT @@GLOBAL.innodb_log_arch_dir;
@@GLOBAL.innodb_log_arch_dir
./
NULL Expected
SELECT VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
WHERE VARIABLE_NAME='innodb_log_arch_dir';
VARIABLE_VALUE
./
empty string Expected
SELECT @@innodb_log_arch_dir;
@@innodb_log_arch_dir
./
NULL Expected
SELECT @@innodb_log_arch_dir;
@@innodb_log_arch_dir
./
NULL Expected
SELECT @@local.innodb_log_arch_dir;
ERROR HY000: Variable 'innodb_log_arch_dir' is a GLOBAL variable
Expected error 'Variable is a GLOBAL variable'
SELECT @@SESSION.innodb_log_arch_dir;
ERROR HY000: Variable 'innodb_log_arch_dir' is a GLOBAL variable
Expected error 'Variable is a GLOBAL variable'
SELECT @@GLOBAL.innodb_log_arch_dir;
@@GLOBAL.innodb_log_arch_dir
./
NULL Expected
SELECT innodb_log_arch_dir = @@SESSION.innodb_log_arch_dir;
ERROR 42S22: Unknown column 'innodb_log_arch_dir' in 'field list'
Expected error Unknown column 'innodb_log_arch_dir' in 'field list'
SELECT @@GLOBAL.innodb_log_arch_expire_sec INTO @save;
SELECT @@GLOBAL.innodb_log_arch_expire_sec;
@@GLOBAL.innodb_log_arch_expire_sec
0
0 Expected
SET @@GLOBAL.innodb_log_arch_expire_sec=1;
SELECT @@GLOBAL.innodb_log_arch_expire_sec;
@@GLOBAL.innodb_log_arch_expire_sec
1
1 Expected
SELECT VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
WHERE VARIABLE_NAME='innodb_log_arch_expire_sec';
VARIABLE_VALUE
1
1 Expected
SELECT @@innodb_log_arch_expire_sec;
@@innodb_log_arch_expire_sec
1
1 Expected
SELECT @@innodb_log_arch_expire_sec;
@@innodb_log_arch_expire_sec
1
1 Expected
SELECT @@local.innodb_log_arch_expire_sec;
ERROR HY000: Variable 'innodb_log_arch_expire_sec' is a GLOBAL variable
Expected error 'Variable is a GLOBAL variable'
SELECT @@SESSION.innodb_log_arch_expire_sec;
ERROR HY000: Variable 'innodb_log_arch_expire_sec' is a GLOBAL variable
Expected error 'Variable is a GLOBAL variable'
SELECT @@GLOBAL.innodb_log_arch_expire_sec;
@@GLOBAL.innodb_log_arch_expire_sec
1
1 Expected
SELECT innodb_log_arch_expire_sec = @@SESSION.innodb_log_arch_expire_sec;
ERROR 42S22: Unknown column 'innodb_log_arch_expire_sec' in 'field list'
Expected error Unknown column 'innodb_log_arch_expire_sec' in 'field list'
SET @@GLOBAL.innodb_log_arch_expire_sec = @save;
SELECT @@GLOBAL.innodb_log_archive;
@@GLOBAL.innodb_log_archive
0
0 Expected
SET @save_innodb_log_archive = @@GLOBAL.innodb_log_archive;
SET @@GLOBAL.innodb_log_archive=1;
SELECT @@GLOBAL.innodb_log_archive;
@@GLOBAL.innodb_log_archive
1
1 Expected
SELECT VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
WHERE VARIABLE_NAME='innodb_log_archive';
VARIABLE_VALUE
ON
ON Expected
SET @@GLOBAL.innodb_log_archive = @save_innodb_log_archive;
SELECT @@innodb_log_archive;
@@innodb_log_archive
0
0 Expected
SELECT @@innodb_log_archive;
@@innodb_log_archive
0
0 Expected
SELECT @@local.innodb_log_archive;
ERROR HY000: Variable 'innodb_log_archive' is a GLOBAL variable
Expected error 'Variable is a GLOBAL variable'
SELECT @@SESSION.innodb_log_archive;
ERROR HY000: Variable 'innodb_log_archive' is a GLOBAL variable
Expected error 'Variable is a GLOBAL variable'
SELECT @@GLOBAL.innodb_log_archive;
@@GLOBAL.innodb_log_archive
0
0 Expected
SELECT innodb_log_archive = @@SESSION.innodb_log_archive;
ERROR 42S22: Unknown column 'innodb_log_archive' in 'field list'
Expected error Unknown column 'innodb_log_archive' in 'field list'
SET @orig = @@global.innodb_log_checksum_algorithm;
SELECT @orig;
@orig
INNODB
SET GLOBAL innodb_log_checksum_algorithm = 'crc32';
SELECT @@global.innodb_log_checksum_algorithm;
@@global.innodb_log_checksum_algorithm
CRC32
SET GLOBAL innodb_log_checksum_algorithm = 'strict_crc32';
SELECT @@global.innodb_log_checksum_algorithm;
@@global.innodb_log_checksum_algorithm
STRICT_CRC32
SET GLOBAL innodb_log_checksum_algorithm = 'innodb';
SELECT @@global.innodb_log_checksum_algorithm;
@@global.innodb_log_checksum_algorithm
INNODB
SET GLOBAL innodb_log_checksum_algorithm = 'strict_innodb';
SELECT @@global.innodb_log_checksum_algorithm;
@@global.innodb_log_checksum_algorithm
STRICT_INNODB
SET GLOBAL innodb_log_checksum_algorithm = 'none';
SELECT @@global.innodb_log_checksum_algorithm;
@@global.innodb_log_checksum_algorithm
NONE
SET GLOBAL innodb_log_checksum_algorithm = 'strict_none';
SELECT @@global.innodb_log_checksum_algorithm;
@@global.innodb_log_checksum_algorithm
STRICT_NONE
SET GLOBAL innodb_log_checksum_algorithm = '';
ERROR 42000: Variable 'innodb_log_checksum_algorithm' can't be set to the value of ''
SELECT @@global.innodb_log_checksum_algorithm;
@@global.innodb_log_checksum_algorithm
STRICT_NONE
SET GLOBAL innodb_log_checksum_algorithm = 'foobar';
ERROR 42000: Variable 'innodb_log_checksum_algorithm' can't be set to the value of 'foobar'
SELECT @@global.innodb_log_checksum_algorithm;
@@global.innodb_log_checksum_algorithm
STRICT_NONE
SET GLOBAL innodb_log_checksum_algorithm = 123;
ERROR 42000: Variable 'innodb_log_checksum_algorithm' can't be set to the value of '123'
SELECT @@global.innodb_log_checksum_algorithm;
@@global.innodb_log_checksum_algorithm
STRICT_NONE
SET GLOBAL innodb_log_checksum_algorithm = @orig;
SELECT @@global.innodb_log_checksum_algorithm;
@@global.innodb_log_checksum_algorithm
INNODB
SET @start_value = @@GLOBAL.innodb_priority_cleaner;
SELECT @@GLOBAL.innodb_priority_cleaner;
@@GLOBAL.innodb_priority_cleaner
0
SELECT @@SESSION.innodb_priority_cleaner;
ERROR HY000: Variable 'innodb_priority_cleaner' is a GLOBAL variable
SET GLOBAL innodb_priority_cleaner='OFF';
SELECT @@GLOBAL.innodb_priority_cleaner;
@@GLOBAL.innodb_priority_cleaner
0
SET GLOBAL innodb_priority_cleaner='ON';
SELECT @@GLOBAL.innodb_priority_cleaner;
@@GLOBAL.innodb_priority_cleaner
1
SET GLOBAL innodb_priority_cleaner=0;
SELECT @@GLOBAL.innodb_priority_cleaner;
@@GLOBAL.innodb_priority_cleaner
0
SET GLOBAL innodb_priority_cleaner=1;
SELECT @@GLOBAL.innodb_priority_cleaner;
@@GLOBAL.innodb_priority_cleaner
1
SET GLOBAL innodb_priority_cleaner=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_priority_cleaner'
SET GLOBAL innodb_priority_cleaner=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_priority_cleaner'
SET GLOBAL innodb_priority_cleaner=2;
ERROR 42000: Variable 'innodb_priority_cleaner' can't be set to the value of '2'
SET GLOBAL innodb_priority_cleaner='foo';
ERROR 42000: Variable 'innodb_priority_cleaner' can't be set to the value of 'foo'
SET GLOBAL innodb_priority_cleaner = @start_value;
SET @start_value = @@GLOBAL.innodb_priority_io;
SELECT @@GLOBAL.innodb_priority_io;
@@GLOBAL.innodb_priority_io
0
SELECT @@SESSION.innodb_priority_io;
ERROR HY000: Variable 'innodb_priority_io' is a GLOBAL variable
SET GLOBAL innodb_priority_io='OFF';
SELECT @@GLOBAL.innodb_priority_io;
@@GLOBAL.innodb_priority_io
0
SET GLOBAL innodb_priority_io='ON';
SELECT @@GLOBAL.innodb_priority_io;
@@GLOBAL.innodb_priority_io
1
SET GLOBAL innodb_priority_io=0;
SELECT @@GLOBAL.innodb_priority_io;
@@GLOBAL.innodb_priority_io
0
SET GLOBAL innodb_priority_io=1;
SELECT @@GLOBAL.innodb_priority_io;
@@GLOBAL.innodb_priority_io
1
SET GLOBAL innodb_priority_io=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_priority_io'
SET GLOBAL innodb_priority_io=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_priority_io'
SET GLOBAL innodb_priority_io=2;
ERROR 42000: Variable 'innodb_priority_io' can't be set to the value of '2'
SET GLOBAL innodb_priority_io='foo';
ERROR 42000: Variable 'innodb_priority_io' can't be set to the value of 'foo'
SET GLOBAL innodb_priority_io = @start_value;
SET @start_value = @@GLOBAL.innodb_priority_master;
SELECT @@GLOBAL.innodb_priority_master;
@@GLOBAL.innodb_priority_master
0
SELECT @@SESSION.innodb_priority_master;
ERROR HY000: Variable 'innodb_priority_master' is a GLOBAL variable
SET GLOBAL innodb_priority_master='OFF';
SELECT @@GLOBAL.innodb_priority_master;
@@GLOBAL.innodb_priority_master
0
SET GLOBAL innodb_priority_master='ON';
SELECT @@GLOBAL.innodb_priority_master;
@@GLOBAL.innodb_priority_master
1
SET GLOBAL innodb_priority_master=0;
SELECT @@GLOBAL.innodb_priority_master;
@@GLOBAL.innodb_priority_master
0
SET GLOBAL innodb_priority_master=1;
SELECT @@GLOBAL.innodb_priority_master;
@@GLOBAL.innodb_priority_master
1
SET GLOBAL innodb_priority_master=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_priority_master'
SET GLOBAL innodb_priority_master=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_priority_master'
SET GLOBAL innodb_priority_master=2;
ERROR 42000: Variable 'innodb_priority_master' can't be set to the value of '2'
SET GLOBAL innodb_priority_master='foo';
ERROR 42000: Variable 'innodb_priority_master' can't be set to the value of 'foo'
SET GLOBAL innodb_priority_master = @start_value;
SET @start_value = @@GLOBAL.innodb_priority_purge;
SELECT @@GLOBAL.innodb_priority_purge;
@@GLOBAL.innodb_priority_purge
0
SELECT @@SESSION.innodb_priority_purge;
ERROR HY000: Variable 'innodb_priority_purge' is a GLOBAL variable
SET GLOBAL innodb_priority_purge='OFF';
SELECT @@GLOBAL.innodb_priority_purge;
@@GLOBAL.innodb_priority_purge
0
SET GLOBAL innodb_priority_purge='ON';
SELECT @@GLOBAL.innodb_priority_purge;
@@GLOBAL.innodb_priority_purge
1
SET GLOBAL innodb_priority_purge=0;
SELECT @@GLOBAL.innodb_priority_purge;
@@GLOBAL.innodb_priority_purge
0
SET GLOBAL innodb_priority_purge=1;
SELECT @@GLOBAL.innodb_priority_purge;
@@GLOBAL.innodb_priority_purge
1
SET GLOBAL innodb_priority_purge=1.1;
ERROR 42000: Incorrect argument type to variable 'innodb_priority_purge'
SET GLOBAL innodb_priority_purge=1e1;
ERROR 42000: Incorrect argument type to variable 'innodb_priority_purge'
SET GLOBAL innodb_priority_purge=2;
ERROR 42000: Variable 'innodb_priority_purge' can't be set to the value of '2'
SET GLOBAL innodb_priority_purge='foo';
ERROR 42000: Variable 'innodb_priority_purge' can't be set to the value of 'foo'
SET GLOBAL innodb_priority_purge = @start_value;
--source include/have_debug.inc
--source include/have_xtradb.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_cleaner_eviction_factor;
# Default value
SELECT @@GLOBAL.innodb_cleaner_eviction_factor;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_cleaner_eviction_factor;
# Correct values
SET GLOBAL innodb_cleaner_eviction_factor='OFF';
SELECT @@GLOBAL.innodb_cleaner_eviction_factor;
SET GLOBAL innodb_cleaner_eviction_factor='ON';
SELECT @@GLOBAL.innodb_cleaner_eviction_factor;
SET GLOBAL innodb_cleaner_eviction_factor=0;
SELECT @@GLOBAL.innodb_cleaner_eviction_factor;
SET GLOBAL innodb_cleaner_eviction_factor=1;
SELECT @@GLOBAL.innodb_cleaner_eviction_factor;
# Incorrect values
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_eviction_factor=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_eviction_factor=1e1;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_cleaner_eviction_factor=2;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_cleaner_eviction_factor='foo';
SET GLOBAL innodb_cleaner_eviction_factor = @start_value;
--source include/have_debug.inc
--source include/have_xtradb.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_cleaner_flush_chunk_size;
# Default value
SELECT @@GLOBAL.innodb_cleaner_flush_chunk_size;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_cleaner_flush_chunk_size;
# Correct values
SET GLOBAL innodb_cleaner_flush_chunk_size=1;
SELECT @@GLOBAL.innodb_cleaner_flush_chunk_size;
SET GLOBAL innodb_cleaner_flush_chunk_size=1000;
SELECT @@GLOBAL.innodb_cleaner_flush_chunk_size;
SET GLOBAL innodb_cleaner_flush_chunk_size=4294967295;
SELECT @@GLOBAL.innodb_cleaner_flush_chunk_size;
# Incorrect values
SET GLOBAL innodb_cleaner_flush_chunk_size=0;
SELECT @@GLOBAL.innodb_cleaner_flush_chunk_size;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_flush_chunk_size=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_flush_chunk_size=1e1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_flush_chunk_size='foo';
SET GLOBAL innodb_cleaner_flush_chunk_size = @start_value;
--source include/have_debug.inc
--source include/have_xtradb.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_cleaner_free_list_lwm;
# Default value
SELECT @@GLOBAL.innodb_cleaner_free_list_lwm;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_cleaner_free_list_lwm;
# Correct values
SET GLOBAL innodb_cleaner_free_list_lwm=0;
SELECT @@GLOBAL.innodb_cleaner_free_list_lwm;
SET GLOBAL innodb_cleaner_free_list_lwm=1;
SELECT @@GLOBAL.innodb_cleaner_free_list_lwm;
SET GLOBAL innodb_cleaner_free_list_lwm=99;
SELECT @@GLOBAL.innodb_cleaner_free_list_lwm;
SET GLOBAL innodb_cleaner_free_list_lwm=100;
SELECT @@GLOBAL.innodb_cleaner_free_list_lwm;
# Incorrect values
SET GLOBAL innodb_cleaner_free_list_lwm=101;
SELECT @@innodb_cleaner_free_list_lwm;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_free_list_lwm=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_free_list_lwm=1e1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_free_list_lwm='foo';
SET GLOBAL innodb_cleaner_free_list_lwm = @start_value;
--source include/have_debug.inc
--source include/have_xtradb.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_cleaner_lru_chunk_size;
# Default value
SELECT @@GLOBAL.innodb_cleaner_lru_chunk_size;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_cleaner_lru_chunk_size;
# Correct values
SET GLOBAL innodb_cleaner_lru_chunk_size=1;
SELECT @@GLOBAL.innodb_cleaner_lru_chunk_size;
SET GLOBAL innodb_cleaner_lru_chunk_size=1000;
SELECT @@GLOBAL.innodb_cleaner_lru_chunk_size;
SET GLOBAL innodb_cleaner_lru_chunk_size=4294967295;
SELECT @@GLOBAL.innodb_cleaner_lru_chunk_size;
# Incorrect values
SET GLOBAL innodb_cleaner_lru_chunk_size=0;
SELECT @@GLOBAL.innodb_cleaner_lru_chunk_size;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_lru_chunk_size=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_lru_chunk_size=1e1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_lru_chunk_size='foo';
SET GLOBAL innodb_cleaner_lru_chunk_size = @start_value;
--source include/have_xtradb.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_cleaner_lsn_age_factor;
# Default value
SELECT @@GLOBAL.innodb_cleaner_lsn_age_factor;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_cleaner_lsn_age_factor;
# Correct values
SET GLOBAL innodb_cleaner_lsn_age_factor='legacy';
SELECT @@GLOBAL.innodb_cleaner_lsn_age_factor;
SET GLOBAL innodb_cleaner_lsn_age_factor='high_checkpoint';
SELECT @@GLOBAL.innodb_cleaner_lsn_age_factor;
# Incorrect values
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_lsn_age_factor=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_lsn_age_factor=1e1;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_cleaner_lsn_age_factor='foo';
SET GLOBAL innodb_cleaner_lsn_age_factor = @start_value;
--source include/have_debug.inc
--source include/have_xtradb.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_cleaner_max_flush_time;
# Default value
SELECT @@GLOBAL.innodb_cleaner_max_flush_time;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_cleaner_max_flush_time;
# Correct values
SET GLOBAL innodb_cleaner_max_flush_time=0;
SELECT @@GLOBAL.innodb_cleaner_max_flush_time;
SET GLOBAL innodb_cleaner_max_flush_time=1000;
SELECT @@GLOBAL.innodb_cleaner_max_flush_time;
SET GLOBAL innodb_cleaner_max_flush_time=4294967295;
SELECT @@GLOBAL.innodb_cleaner_max_flush_time;
# Incorrect values
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_max_flush_time=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_max_flush_time=1e1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_max_flush_time='foo';
SET GLOBAL innodb_cleaner_max_flush_time = @start_value;
--source include/have_debug.inc
--source include/have_xtradb.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_cleaner_max_lru_time;
# Default value
SELECT @@GLOBAL.innodb_cleaner_max_lru_time;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_cleaner_max_lru_time;
# Correct values
SET GLOBAL innodb_cleaner_max_lru_time=0;
SELECT @@GLOBAL.innodb_cleaner_max_lru_time;
SET GLOBAL innodb_cleaner_max_lru_time=1000;
SELECT @@GLOBAL.innodb_cleaner_max_lru_time;
SET GLOBAL innodb_cleaner_max_lru_time=4294967295;
SELECT @@GLOBAL.innodb_cleaner_max_lru_time;
# Incorrect values
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_max_lru_time=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_max_lru_time=1e1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_cleaner_max_lru_time='foo';
SET GLOBAL innodb_cleaner_max_lru_time = @start_value;
--source include/have_xtradb.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_empty_free_list_algorithm;
# Default value
SELECT @@GLOBAL.innodb_empty_free_list_algorithm;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_empty_free_list_algorithm;
# Correct values
SET GLOBAL innodb_empty_free_list_algorithm='legacy';
SELECT @@GLOBAL.innodb_empty_free_list_algorithm;
SET GLOBAL innodb_empty_free_list_algorithm='backoff';
SELECT @@GLOBAL.innodb_empty_free_list_algorithm;
# Incorrect values
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_empty_free_list_algorithm=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_empty_free_list_algorithm=1e1;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_empty_free_list_algorithm=2;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_empty_free_list_algorithm='foo';
SET GLOBAL innodb_empty_free_list_algorithm = @start_value;
--source include/have_xtradb.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_foreground_preflush;
# Default value
SELECT @@GLOBAL.innodb_foreground_preflush;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_foreground_preflush;
# Correct values
SET GLOBAL innodb_foreground_preflush='sync_preflush';
SELECT @@GLOBAL.innodb_foreground_preflush;
SET GLOBAL innodb_foreground_preflush='exponential_backoff';
SELECT @@GLOBAL.innodb_foreground_preflush;
# Incorrect values
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_foreground_preflush=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_foreground_preflush=1e1;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_foreground_preflush=2;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_foreground_preflush='foo';
SET GLOBAL innodb_foreground_preflush = @start_value;
#######################################################
# Basic test for innodb_log_arch_dir variable #
#######################################################
--source include/have_xtradb.inc
let $datadir= `select @@datadir`;
####################################################################
# Displaying default value #
####################################################################
--replace_result $datadir ./
SELECT @@GLOBAL.innodb_log_arch_dir;
--echo NULL Expected
####################################################################
# Check if Value can set #
####################################################################
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SET @@GLOBAL.innodb_log_arch_dir=1;
--echo Expected error 'Read only variable'
--replace_result $datadir ./
SELECT @@GLOBAL.innodb_log_arch_dir;
--echo NULL Expected
--replace_result $datadir ./
SELECT VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
WHERE VARIABLE_NAME='innodb_log_arch_dir';
--echo empty string Expected
############################################
# Check accessing variable without GLOBAL #
############################################
--replace_result $datadir ./
SELECT @@innodb_log_arch_dir;
--echo NULL Expected
##########################################################################
# Check if innodb_log_arch_dir can be accessed without @@ sign #
##########################################################################
--replace_result $datadir ./
SELECT @@innodb_log_arch_dir;
--echo NULL Expected
--Error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@local.innodb_log_arch_dir;
--echo Expected error 'Variable is a GLOBAL variable'
--Error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_log_arch_dir;
--echo Expected error 'Variable is a GLOBAL variable'
--replace_result $datadir ./
SELECT @@GLOBAL.innodb_log_arch_dir;
--echo NULL Expected
--Error ER_BAD_FIELD_ERROR
SELECT innodb_log_arch_dir = @@SESSION.innodb_log_arch_dir;
--echo Expected error Unknown column 'innodb_log_arch_dir' in 'field list'
###############################################################
# Basic test for innodb_log_arch_expire_sec variable #
###############################################################
--source include/have_xtradb.inc
SELECT @@GLOBAL.innodb_log_arch_expire_sec INTO @save;
####################################################################
# Displaying default value #
####################################################################
SELECT @@GLOBAL.innodb_log_arch_expire_sec;
--echo 0 Expected
####################################################################
# Check if Value can set #
####################################################################
SET @@GLOBAL.innodb_log_arch_expire_sec=1;
SELECT @@GLOBAL.innodb_log_arch_expire_sec;
--echo 1 Expected
SELECT VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
WHERE VARIABLE_NAME='innodb_log_arch_expire_sec';
--echo 1 Expected
############################################
# Check accessing variable without GLOBAL #
############################################
SELECT @@innodb_log_arch_expire_sec;
--echo 1 Expected
##################################################################################
# Check if innodb_log_arch_expire_sec can be accessed without @@ sign #
##################################################################################
SELECT @@innodb_log_arch_expire_sec;
--echo 1 Expected
--Error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@local.innodb_log_arch_expire_sec;
--echo Expected error 'Variable is a GLOBAL variable'
--Error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_log_arch_expire_sec;
--echo Expected error 'Variable is a GLOBAL variable'
SELECT @@GLOBAL.innodb_log_arch_expire_sec;
--echo 1 Expected
--Error ER_BAD_FIELD_ERROR
SELECT innodb_log_arch_expire_sec = @@SESSION.innodb_log_arch_expire_sec;
--echo Expected error Unknown column 'innodb_log_arch_expire_sec' in 'field list'
SET @@GLOBAL.innodb_log_arch_expire_sec = @save;
###################################################
# Basic test for innodb_log_archive variable #
###################################################
--source include/have_xtradb.inc
####################################################################
# Displaying default value #
####################################################################
SELECT @@GLOBAL.innodb_log_archive;
--echo 0 Expected
####################################################################
# Check if Value can set #
####################################################################
SET @save_innodb_log_archive = @@GLOBAL.innodb_log_archive;
SET @@GLOBAL.innodb_log_archive=1;
SELECT @@GLOBAL.innodb_log_archive;
--echo 1 Expected
SELECT VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
WHERE VARIABLE_NAME='innodb_log_archive';
--echo ON Expected
SET @@GLOBAL.innodb_log_archive = @save_innodb_log_archive;
############################################
# Check accessing variable without GLOBAL #
############################################
SELECT @@innodb_log_archive;
--echo 0 Expected
##########################################################################
# Check if innodb_log_archive can be accessed without @@ sign #
##########################################################################
SELECT @@innodb_log_archive;
--echo 0 Expected
--Error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@local.innodb_log_archive;
--echo Expected error 'Variable is a GLOBAL variable'
--Error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_log_archive;
--echo Expected error 'Variable is a GLOBAL variable'
SELECT @@GLOBAL.innodb_log_archive;
--echo 0 Expected
--Error ER_BAD_FIELD_ERROR
SELECT innodb_log_archive = @@SESSION.innodb_log_archive;
--echo Expected error Unknown column 'innodb_log_archive' in 'field list'
--source include/have_xtradb.inc
# Check the default value
SET @orig = @@global.innodb_log_checksum_algorithm;
SELECT @orig;
SET GLOBAL innodb_log_checksum_algorithm = 'crc32';
SELECT @@global.innodb_log_checksum_algorithm;
SET GLOBAL innodb_log_checksum_algorithm = 'strict_crc32';
SELECT @@global.innodb_log_checksum_algorithm;
SET GLOBAL innodb_log_checksum_algorithm = 'innodb';
SELECT @@global.innodb_log_checksum_algorithm;
SET GLOBAL innodb_log_checksum_algorithm = 'strict_innodb';
SELECT @@global.innodb_log_checksum_algorithm;
SET GLOBAL innodb_log_checksum_algorithm = 'none';
SELECT @@global.innodb_log_checksum_algorithm;
SET GLOBAL innodb_log_checksum_algorithm = 'strict_none';
SELECT @@global.innodb_log_checksum_algorithm;
-- error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_log_checksum_algorithm = '';
SELECT @@global.innodb_log_checksum_algorithm;
-- error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_log_checksum_algorithm = 'foobar';
SELECT @@global.innodb_log_checksum_algorithm;
-- error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_log_checksum_algorithm = 123;
SELECT @@global.innodb_log_checksum_algorithm;
SET GLOBAL innodb_log_checksum_algorithm = @orig;
SELECT @@global.innodb_log_checksum_algorithm;
--source include/have_debug.inc
--source include/have_xtradb.inc
--source include/linux.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_priority_cleaner;
# Default value
SELECT @@GLOBAL.innodb_priority_cleaner;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_priority_cleaner;
# Correct values
SET GLOBAL innodb_priority_cleaner='OFF';
SELECT @@GLOBAL.innodb_priority_cleaner;
SET GLOBAL innodb_priority_cleaner='ON';
SELECT @@GLOBAL.innodb_priority_cleaner;
SET GLOBAL innodb_priority_cleaner=0;
SELECT @@GLOBAL.innodb_priority_cleaner;
SET GLOBAL innodb_priority_cleaner=1;
SELECT @@GLOBAL.innodb_priority_cleaner;
# Incorrect values
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_priority_cleaner=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_priority_cleaner=1e1;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_priority_cleaner=2;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_priority_cleaner='foo';
SET GLOBAL innodb_priority_cleaner = @start_value;
--source include/have_debug.inc
--source include/have_xtradb.inc
--source include/linux.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_priority_io;
# Default value
SELECT @@GLOBAL.innodb_priority_io;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_priority_io;
# Correct values
SET GLOBAL innodb_priority_io='OFF';
SELECT @@GLOBAL.innodb_priority_io;
SET GLOBAL innodb_priority_io='ON';
SELECT @@GLOBAL.innodb_priority_io;
SET GLOBAL innodb_priority_io=0;
SELECT @@GLOBAL.innodb_priority_io;
SET GLOBAL innodb_priority_io=1;
SELECT @@GLOBAL.innodb_priority_io;
# Incorrect values
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_priority_io=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_priority_io=1e1;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_priority_io=2;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_priority_io='foo';
SET GLOBAL innodb_priority_io = @start_value;
--source include/have_debug.inc
--source include/have_xtradb.inc
--source include/linux.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_priority_master;
# Default value
SELECT @@GLOBAL.innodb_priority_master;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_priority_master;
# Correct values
SET GLOBAL innodb_priority_master='OFF';
SELECT @@GLOBAL.innodb_priority_master;
SET GLOBAL innodb_priority_master='ON';
SELECT @@GLOBAL.innodb_priority_master;
SET GLOBAL innodb_priority_master=0;
SELECT @@GLOBAL.innodb_priority_master;
SET GLOBAL innodb_priority_master=1;
SELECT @@GLOBAL.innodb_priority_master;
# Incorrect values
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_priority_master=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_priority_master=1e1;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_priority_master=2;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_priority_master='foo';
SET GLOBAL innodb_priority_master = @start_value;
--source include/have_debug.inc
--source include/have_xtradb.inc
--source include/linux.inc
# A dynamic, global variable
SET @start_value = @@GLOBAL.innodb_priority_purge;
# Default value
SELECT @@GLOBAL.innodb_priority_purge;
# Global only
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@SESSION.innodb_priority_purge;
# Correct values
SET GLOBAL innodb_priority_purge='OFF';
SELECT @@GLOBAL.innodb_priority_purge;
SET GLOBAL innodb_priority_purge='ON';
SELECT @@GLOBAL.innodb_priority_purge;
SET GLOBAL innodb_priority_purge=0;
SELECT @@GLOBAL.innodb_priority_purge;
SET GLOBAL innodb_priority_purge=1;
SELECT @@GLOBAL.innodb_priority_purge;
# Incorrect values
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_priority_purge=1.1;
--error ER_WRONG_TYPE_FOR_VAR
SET GLOBAL innodb_priority_purge=1e1;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_priority_purge=2;
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL innodb_priority_purge='foo';
SET GLOBAL innodb_priority_purge = @start_value;
......@@ -5,7 +5,7 @@
--source include/have_debug.inc
--source include/master-slave.inc
--source include/have_binlog_format_row.inc
--source include/have_xtradb.inc
--source include/have_innodb.inc
--disable_warnings
drop table if exists t1;
......
......@@ -12,7 +12,7 @@
# Slow test, don't run during staging part
--source include/not_staging.inc
--source include/have_xtradb.inc
--source include/have_innodb.inc
let $engine_type= InnoDB;
# InnoDB does not support Merge tables (affects include/index_merge1.inc)
......
......@@ -8,8 +8,7 @@
# on the presence of the log tables (which are CSV-based).
--source include/have_csv.inc
# Check that XtraDB is enabled as result depends on it
-- source include/have_xtradb.inc
-- source include/have_innodb.inc
# Save the initial number of concurrent sessions
--source include/count_sessions.inc
......
......@@ -3,7 +3,7 @@
# available (since these engines inject tables into INFORMATION_SCHEMA).
--source include/not_embedded.inc
--source include/have_xtradb.inc
--source include/have_innodb.inc
--source include/have_perfschema.inc
--source include/not_staging.inc
......
......@@ -8,17 +8,6 @@ source include/have_log_bin.inc;
CALL mtr.add_suppression("Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT.");
--disable_warnings
drop table if exists t1,t2,t3;
drop database if exists mysqltest;
drop view if exists v1;
--error 0,ER_NONEXISTING_GRANT,ER_NONEXISTING_TABLE_GRANT
revoke all privileges on mysqltest.t1 from mysqltest_1@localhost;
--error 0,ER_NONEXISTING_GRANT,ER_NONEXISTING_TABLE_GRANT
revoke all privileges on mysqltest.* from mysqltest_1@localhost;
delete from mysql.user where user=_binary'mysqltest_1';
--enable_warnings
create table t1(id1 int not null auto_increment primary key, t char(12));
create table t2(id2 int not null, t char(12));
create table t3(id3 int not null, t char(12), index(id3));
......@@ -372,9 +361,7 @@ drop table t1, t2;
connect (root,localhost,root,,test,$MASTER_MYPORT,$MASTER_MYSOCK);
connection root;
--disable_warnings
create database mysqltest;
--enable_warnings
create table mysqltest.t1 (a int, b int, primary key (a));
create table mysqltest.t2 (a int, b int, primary key (a));
create table mysqltest.t3 (a int, b int, primary key (a));
......@@ -415,22 +402,6 @@ update t1,t2 set t1.col1 = (select max(col1) from t1) where t1.col1 = t2.col1;
delete t1 from t1,t2 where t1.col1 < (select max(col1) from t1) and t1.col1 = t2.col1;
drop table t1,t2;
# Test for Bug#5837 delete with outer join and const tables
--disable_warnings
create table t1 (
aclid bigint not null primary key,
status tinyint(1) not null
) engine = innodb;
create table t2 (
refid bigint not null primary key,
aclid bigint, index idx_acl(aclid)
) engine = innodb;
--enable_warnings
insert into t2 values(1,null);
delete t2, t1 from t2 left join t1 on (t2.aclid=t1.aclid) where t2.refid='1';
drop table t1, t2;
#
# Bug#19225 unchecked error leads to server crash
#
......@@ -441,47 +412,6 @@ delete from t1,t2 using t1,t2 where t1.a=(select a from t1);
drop table t1, t2;
# End of 4.1 tests
#
# Test for Bug#1980.
#
--disable_warnings
create table t1 ( c char(8) not null ) engine=innodb;
--enable_warnings
insert into t1 values ('0'),('1'),('2'),('3'),('4'),('5'),('6'),('7'),('8'),('9');
insert into t1 values ('A'),('B'),('C'),('D'),('E'),('F');
alter table t1 add b char(8) not null;
alter table t1 add a char(8) not null;
alter table t1 add primary key (a,b,c);
update t1 set a=c, b=c;
create table t2 like t1;
insert into t2 select * from t1;
delete t1,t2 from t2,t1 where t1.a<'B' and t2.b=t1.b;
drop table t1,t2;
--disable_warnings
create table t1 ( c char(8) not null ) engine=innodb;
--enable_warnings
insert into t1 values ('0'),('1'),('2'),('3'),('4'),('5'),('6'),('7'),('8'),('9');
insert into t1 values ('A'),('B'),('C'),('D'),('E'),('F');
alter table t1 add b char(8) not null;
alter table t1 add a char(8) not null;
alter table t1 add primary key (a,b,c);
update t1 set a=c, b=c;
create table t2 like t1;
insert into t2 select * from t1;
delete t1,t2 from t2,t1 where t1.a<'B' and t2.b=t1.b;
drop table t1,t2;
#
# Test alter table and a concurrent multi update
# (Before we have introduced data-lock-aware metadata locks
......@@ -618,9 +548,6 @@ set @@session.binlog_format= @sav_binlog_format;
#
# prepare
--disable_warnings
drop table if exists t1, t2, t3;
--enable_warnings
CREATE TABLE t1 (a int, PRIMARY KEY (a));
CREATE TABLE t2 (a int, PRIMARY KEY (a));
CREATE TABLE t3 (a int, PRIMARY KEY (a)) ENGINE=MyISAM;
......@@ -1057,54 +984,3 @@ deallocate prepare stmt1;
drop view v3,v2,v1;
drop table t1,t2,t3;
--echo end of 5.5 tests
--source include/have_xtradb.inc
--echo
--echo # Bug mdev-5970
--echo # Bug#13256831 - ERROR 1032 (HY000): CAN'T FIND RECORD
--echo
CREATE TABLE t1 (f1 INT PRIMARY KEY, f2 INT) ENGINE=InnoDB;
CREATE TABLE t2 (f1 INT PRIMARY KEY, f2 INT) ENGINE=InnoDB;
INSERT INTO t1 VALUES (5, 7);
INSERT INTO t2 VALUES (6, 97);
CREATE ALGORITHM = MERGE VIEW v1 AS
SELECT a2.f1 AS f1, a2.f2 AS f2
FROM t1 AS a1 JOIN t2 AS a2 ON a1.f2 > a2.f1
WITH LOCAL CHECK OPTION;
SELECT * FROM v1;
UPDATE v1 SET f1 = 1;
SELECT * FROM v1;
DROP TABLE t1, t2;
DROP VIEW v1;
--echo #
--echo # MDEV-5973: MySQL Bug#11757486:49539: NON-DESCRIPTIVE ERR (ERROR 0
--echo # FROM STORAGE ENGINE) WITH MULTI-TABLE UPDATE
--echo #
CREATE TABLE table_11757486 (field1 tinyint) ENGINE=INNODB;
INSERT INTO table_11757486 VALUES (0),(0);
SET SESSION SQL_MODE='STRICT_ALL_TABLES';
UPDATE IGNORE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
UPDATE IGNORE table_11757486 SET field1=128;
--error ER_WARN_DATA_OUT_OF_RANGE
UPDATE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
--error ER_WARN_DATA_OUT_OF_RANGE
UPDATE table_11757486 SET field1=128;
SET SESSION SQL_MODE='';
UPDATE IGNORE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
UPDATE IGNORE table_11757486 SET field1=128;
DROP TABLE table_11757486;
SET SESSION SQL_MODE=default;
--echo end of 10.0 tests
......@@ -75,3 +75,101 @@ UPDATE t2 AS A NATURAL JOIN t2 B SET A.pk_2=10,B.pk_2=11;
SELECT * FROM t2;
DROP TABLE t1,t2;
--echo
--echo # Bug mdev-5970
--echo # Bug#13256831 - ERROR 1032 (HY000): CAN'T FIND RECORD
--echo
CREATE TABLE t1 (f1 INT PRIMARY KEY, f2 INT) ENGINE=InnoDB;
CREATE TABLE t2 (f1 INT PRIMARY KEY, f2 INT) ENGINE=InnoDB;
INSERT INTO t1 VALUES (5, 7);
INSERT INTO t2 VALUES (6, 97);
CREATE ALGORITHM = MERGE VIEW v1 AS
SELECT a2.f1 AS f1, a2.f2 AS f2
FROM t1 AS a1 JOIN t2 AS a2 ON a1.f2 > a2.f1
WITH LOCAL CHECK OPTION;
SELECT * FROM v1;
UPDATE v1 SET f1 = 1;
SELECT * FROM v1;
DROP TABLE t1, t2;
DROP VIEW v1;
--echo #
--echo # MDEV-5973: MySQL Bug#11757486:49539: NON-DESCRIPTIVE ERR (ERROR 0
--echo # FROM STORAGE ENGINE) WITH MULTI-TABLE UPDATE
--echo #
CREATE TABLE table_11757486 (field1 tinyint) ENGINE=INNODB;
INSERT INTO table_11757486 VALUES (0),(0);
SET SESSION SQL_MODE='STRICT_ALL_TABLES';
UPDATE IGNORE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
UPDATE IGNORE table_11757486 SET field1=128;
--error ER_WARN_DATA_OUT_OF_RANGE
UPDATE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
--error ER_WARN_DATA_OUT_OF_RANGE
UPDATE table_11757486 SET field1=128;
SET SESSION SQL_MODE='';
UPDATE IGNORE (SELECT 128 as col1) x, table_11757486 SET field1=x.col1;
UPDATE IGNORE table_11757486 SET field1=128;
DROP TABLE table_11757486;
SET SESSION SQL_MODE=default;
# Test for Bug#5837 delete with outer join and const tables
create table t1 (
aclid bigint not null primary key,
status tinyint(1) not null
) engine = innodb;
create table t2 (
refid bigint not null primary key,
aclid bigint, index idx_acl(aclid)
) engine = innodb;
insert into t2 values(1,null);
delete t2, t1 from t2 left join t1 on (t2.aclid=t1.aclid) where t2.refid='1';
drop table t1, t2;
#
# Test for Bug#1980.
#
create table t1 ( c char(8) not null ) engine=innodb;
insert into t1 values ('0'),('1'),('2'),('3'),('4'),('5'),('6'),('7'),('8'),('9');
insert into t1 values ('A'),('B'),('C'),('D'),('E'),('F');
alter table t1 add b char(8) not null;
alter table t1 add a char(8) not null;
alter table t1 add primary key (a,b,c);
update t1 set a=c, b=c;
create table t2 like t1;
insert into t2 select * from t1;
delete t1,t2 from t2,t1 where t1.a<'B' and t2.b=t1.b;
drop table t1,t2;
create table t1 ( c char(8) not null ) engine=innodb;
insert into t1 values ('0'),('1'),('2'),('3'),('4'),('5'),('6'),('7'),('8'),('9');
insert into t1 values ('A'),('B'),('C'),('D'),('E'),('F');
alter table t1 add b char(8) not null;
alter table t1 add a char(8) not null;
alter table t1 add primary key (a,b,c);
update t1 set a=c, b=c;
create table t2 like t1;
insert into t2 select * from t1;
delete t1,t2 from t2,t1 where t1.a<'B' and t2.b=t1.b;
drop table t1,t2;
--source include/have_xtradb.inc
--source include/have_innodb.inc
CREATE TABLE t1 (a INT) ENGINE=InnoDB;
CREATE TABLE t2 (b INT) ENGINE=InnoDB;
......
......@@ -8,7 +8,7 @@
# main code t/rowid_order_innodb.test -> include/rowid_order.inc
#
--source include/have_xtradb.inc
--source include/have_innodb.inc
let $engine_type= InnoDB;
--source include/rowid_order.inc
-- source include/have_xtradb.inc
-- source include/have_innodb.inc
--disable_warnings
drop table if exists t1,t2,t3,t4;
......
#
# MDEV-9214 Server miscalculates the number of XA-capable engines
#
--source include/have_xtradb.inc
--source include/have_innodb.inc
select 1;
......
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