mirror of
https://github.com/MariaDB/server.git
synced 2025-06-06 05:21:19 +03:00
Merge branch bb-10.2-release into bb-10.3-release
This commit is contained in:
commit
a8a925dd22
@ -14,7 +14,8 @@
|
|||||||
# along with this program; if not, write to the Free Software
|
# along with this program; if not, write to the Free Software
|
||||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1335 USA
|
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1335 USA
|
||||||
|
|
||||||
CMAKE_MINIMUM_REQUIRED(VERSION 2.8.7)
|
CMAKE_MINIMUM_REQUIRED(VERSION 2.8.12)
|
||||||
|
PROJECT(MySQL)
|
||||||
|
|
||||||
IF(POLICY CMP0022)
|
IF(POLICY CMP0022)
|
||||||
CMAKE_POLICY(SET CMP0022 NEW)
|
CMAKE_POLICY(SET CMP0022 NEW)
|
||||||
@ -41,8 +42,16 @@ IF(NOT DEFINED MANUFACTURER)
|
|||||||
MARK_AS_ADVANCED(MANUFACTURER)
|
MARK_AS_ADVANCED(MANUFACTURER)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
SET(CMAKE_BUILD_TYPE "RelWithDebInfo" CACHE STRING
|
IF(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
|
||||||
"Choose the type of build, options are: None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel")
|
# Setting build type to RelWithDebInfo as none was specified.")
|
||||||
|
SET(CMAKE_BUILD_TYPE "RelWithDebInfo" CACHE STRING
|
||||||
|
"Choose the type of build, options are: None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel"
|
||||||
|
FORCE)
|
||||||
|
# Set the possible values of build type for cmake-gui
|
||||||
|
SET_PROPERTY(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS
|
||||||
|
"None" "Debug" "Release" "MinSizeRel" "RelWithDebInfo")
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
|
||||||
# MAX_INDEXES - Set the maximum number of indexes per table, default 64
|
# MAX_INDEXES - Set the maximum number of indexes per table, default 64
|
||||||
IF (NOT MAX_INDEXES)
|
IF (NOT MAX_INDEXES)
|
||||||
@ -71,18 +80,8 @@ IF(UNIX AND NOT APPLE)
|
|||||||
MARK_AS_ADVANCED(WITH_PIC)
|
MARK_AS_ADVANCED(WITH_PIC)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
# Optionally set project name, e.g.
|
# This is used by TokuDB only
|
||||||
# foo.xcodeproj (mac) or foo.sln (windows)
|
|
||||||
SET(MYSQL_PROJECT_NAME_DOCSTRING "MySQL project name")
|
SET(MYSQL_PROJECT_NAME_DOCSTRING "MySQL project name")
|
||||||
IF(DEFINED MYSQL_PROJECT_NAME)
|
|
||||||
SET(MYSQL_PROJECT_NAME ${MYSQL_PROJECT_NAME} CACHE STRING
|
|
||||||
${MYSQL_PROJECT_NAME_DOCSTRING} FORCE)
|
|
||||||
ELSE()
|
|
||||||
SET(MYSQL_PROJECT_NAME "MySQL" CACHE STRING
|
|
||||||
${MYSQL_PROJECT_NAME_DOCSTRING} FORCE)
|
|
||||||
MARK_AS_ADVANCED(MYSQL_PROJECT_NAME)
|
|
||||||
ENDIF()
|
|
||||||
PROJECT(${MYSQL_PROJECT_NAME})
|
|
||||||
|
|
||||||
SET(CPACK_PACKAGE_NAME "MariaDB")
|
SET(CPACK_PACKAGE_NAME "MariaDB")
|
||||||
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "MariaDB: a very fast and robust SQL database server")
|
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "MariaDB: a very fast and robust SQL database server")
|
||||||
|
@ -1 +1 @@
|
|||||||
Subproject commit d19c7c69269fdf4e2af8943dd86c12e4e1664afd
|
Subproject commit 180c543704d627a50a52aaf60e24ca14e0ec4686
|
15
mysql-test/main/mdev19198.result
Normal file
15
mysql-test/main/mdev19198.result
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
CREATE TABLE t1 (c INT);
|
||||||
|
CREATE TABLE t2 (c INT);
|
||||||
|
LOCK TABLES t1 WRITE, t2 READ;
|
||||||
|
CREATE TABLE IF NOT EXISTS t1 LIKE t2;
|
||||||
|
Warnings:
|
||||||
|
Note 1050 Table 't1' already exists
|
||||||
|
UNLOCK TABLES;
|
||||||
|
LOCK TABLES t1 READ , t2 READ;
|
||||||
|
CREATE TABLE IF NOT EXISTS t1 LIKE t2;
|
||||||
|
ERROR HY000: Table 't1' was locked with a READ lock and can't be updated
|
||||||
|
UNLOCK TABLES;
|
||||||
|
CREATE TABLE IF NOT EXISTS t1 LIKE t2;
|
||||||
|
Warnings:
|
||||||
|
Note 1050 Table 't1' already exists
|
||||||
|
DROP TABLES t1,t2;
|
15
mysql-test/main/mdev19198.test
Normal file
15
mysql-test/main/mdev19198.test
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
CREATE TABLE t1 (c INT);
|
||||||
|
CREATE TABLE t2 (c INT);
|
||||||
|
|
||||||
|
LOCK TABLES t1 WRITE, t2 READ;
|
||||||
|
CREATE TABLE IF NOT EXISTS t1 LIKE t2;
|
||||||
|
UNLOCK TABLES;
|
||||||
|
|
||||||
|
LOCK TABLES t1 READ , t2 READ;
|
||||||
|
--error ER_TABLE_NOT_LOCKED_FOR_WRITE
|
||||||
|
CREATE TABLE IF NOT EXISTS t1 LIKE t2;
|
||||||
|
UNLOCK TABLES;
|
||||||
|
|
||||||
|
CREATE TABLE IF NOT EXISTS t1 LIKE t2;
|
||||||
|
|
||||||
|
DROP TABLES t1,t2;
|
@ -30,3 +30,38 @@ disconnect con2;
|
|||||||
USE test;
|
USE test;
|
||||||
DROP PROCEDURE p_install;
|
DROP PROCEDURE p_install;
|
||||||
DROP PROCEDURE p_show_vars;
|
DROP PROCEDURE p_show_vars;
|
||||||
|
#
|
||||||
|
# Bug#29363867: LOST CONNECTION TO MYSQL SERVER DURING QUERY
|
||||||
|
#
|
||||||
|
## prepared SET with a plugin variable prevents uninstall
|
||||||
|
install plugin query_response_time soname 'query_response_time';
|
||||||
|
prepare s from 'set global query_response_time_range_base=16';
|
||||||
|
select plugin_status from information_schema.plugins where plugin_name='query_response_time';
|
||||||
|
plugin_status
|
||||||
|
ACTIVE
|
||||||
|
uninstall plugin query_response_time;
|
||||||
|
Warnings:
|
||||||
|
Warning 1620 Plugin is busy and will be uninstalled on shutdown
|
||||||
|
execute s;
|
||||||
|
execute s;
|
||||||
|
select plugin_status from information_schema.plugins where plugin_name='query_response_time';
|
||||||
|
plugin_status
|
||||||
|
DELETED
|
||||||
|
deallocate prepare s;
|
||||||
|
select plugin_status from information_schema.plugins where plugin_name='query_response_time';
|
||||||
|
plugin_status
|
||||||
|
## prepared SET mentioning a plugin otherwise does not prevent uninstall
|
||||||
|
install plugin archive soname 'ha_archive';
|
||||||
|
create table t1 (a int) engine=archive;
|
||||||
|
insert t1 values (1),(2),(3);
|
||||||
|
prepare s from 'set session auto_increment_increment=(select count(*) from t1)';
|
||||||
|
flush tables;
|
||||||
|
select plugin_status from information_schema.plugins where plugin_name='archive';
|
||||||
|
plugin_status
|
||||||
|
ACTIVE
|
||||||
|
uninstall plugin archive;
|
||||||
|
select plugin_status from information_schema.plugins where plugin_name='archive';
|
||||||
|
plugin_status
|
||||||
|
execute s;
|
||||||
|
ERROR 42000: Unknown storage engine 'ARCHIVE'
|
||||||
|
drop table t1;
|
||||||
|
@ -1,3 +1,10 @@
|
|||||||
|
if (!$QUERY_RESPONSE_TIME_SO) {
|
||||||
|
skip Needs query_response_time loadable plugin;
|
||||||
|
}
|
||||||
|
if (!$HA_ARCHIVE_SO) {
|
||||||
|
skip Needs Archive loadable plugin;
|
||||||
|
}
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
--echo # MDEV-5345 - Deadlock between mysql_change_user(), SHOW VARIABLES and
|
--echo # MDEV-5345 - Deadlock between mysql_change_user(), SHOW VARIABLES and
|
||||||
--echo # INSTALL PLUGIN
|
--echo # INSTALL PLUGIN
|
||||||
@ -54,3 +61,31 @@ disconnect con2;
|
|||||||
USE test;
|
USE test;
|
||||||
DROP PROCEDURE p_install;
|
DROP PROCEDURE p_install;
|
||||||
DROP PROCEDURE p_show_vars;
|
DROP PROCEDURE p_show_vars;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # Bug#29363867: LOST CONNECTION TO MYSQL SERVER DURING QUERY
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
--echo ## prepared SET with a plugin variable prevents uninstall
|
||||||
|
install plugin query_response_time soname 'query_response_time';
|
||||||
|
prepare s from 'set global query_response_time_range_base=16';
|
||||||
|
select plugin_status from information_schema.plugins where plugin_name='query_response_time';
|
||||||
|
uninstall plugin query_response_time;
|
||||||
|
execute s;
|
||||||
|
execute s;
|
||||||
|
select plugin_status from information_schema.plugins where plugin_name='query_response_time';
|
||||||
|
deallocate prepare s;
|
||||||
|
select plugin_status from information_schema.plugins where plugin_name='query_response_time';
|
||||||
|
|
||||||
|
--echo ## prepared SET mentioning a plugin otherwise does not prevent uninstall
|
||||||
|
install plugin archive soname 'ha_archive';
|
||||||
|
create table t1 (a int) engine=archive;
|
||||||
|
insert t1 values (1),(2),(3);
|
||||||
|
prepare s from 'set session auto_increment_increment=(select count(*) from t1)';
|
||||||
|
flush tables;
|
||||||
|
select plugin_status from information_schema.plugins where plugin_name='archive';
|
||||||
|
uninstall plugin archive;
|
||||||
|
select plugin_status from information_schema.plugins where plugin_name='archive';
|
||||||
|
--error ER_UNKNOWN_STORAGE_ENGINE
|
||||||
|
execute s;
|
||||||
|
drop table t1;
|
||||||
|
1
mysql-test/main/show_explain.opt
Normal file
1
mysql-test/main/show_explain.opt
Normal file
@ -0,0 +1 @@
|
|||||||
|
--enable-plugin-innodb-lock-waits --enable-plugin-innodb-trx
|
@ -861,7 +861,14 @@ select * from t1 where pk between 10 and 20 for update;
|
|||||||
# run SHOW EXPLAIN on a frozen thread
|
# run SHOW EXPLAIN on a frozen thread
|
||||||
connection default;
|
connection default;
|
||||||
let $save_wait_condition= $wait_condition;
|
let $save_wait_condition= $wait_condition;
|
||||||
let $wait_condition= select State='Sending data' from information_schema.processlist where id=$thr2;
|
let $wait_condition=
|
||||||
|
select 1
|
||||||
|
from information_schema.INNODB_LOCK_WAITS
|
||||||
|
where
|
||||||
|
requesting_trx_id=(select trx_id
|
||||||
|
from information_schema.INNODB_TRX
|
||||||
|
where trx_mysql_thread_id=$thr2);
|
||||||
|
|
||||||
let $thr_default=`select connection_id()`;
|
let $thr_default=`select connection_id()`;
|
||||||
--source include/wait_condition.inc
|
--source include/wait_condition.inc
|
||||||
--echo # do: send_eval show explain for thr2;
|
--echo # do: send_eval show explain for thr2;
|
||||||
|
@ -8487,6 +8487,21 @@ ERROR HY000: View 'test.v1' references invalid table(s) or column(s) or function
|
|||||||
DROP PROCEDURE p1;
|
DROP PROCEDURE p1;
|
||||||
DROP VIEW v1;
|
DROP VIEW v1;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
#
|
||||||
|
# BUG#30366310: USING A FUNCTION TO ASSIGN DEFAULT VALUES TO
|
||||||
|
# 2 OR MORE VARIABLES CRASHES SERVER
|
||||||
|
#
|
||||||
|
create function f1() returns bigint return now()-1|
|
||||||
|
create procedure p1()
|
||||||
|
begin
|
||||||
|
declare b, c bigint default f1();
|
||||||
|
select b-c;
|
||||||
|
end|
|
||||||
|
call p1()|
|
||||||
|
b-c
|
||||||
|
0
|
||||||
|
drop procedure p1|
|
||||||
|
drop function f1|
|
||||||
#End of 10.2 tests
|
#End of 10.2 tests
|
||||||
#
|
#
|
||||||
# MDEV-12007 Allow ROW variables as a cursor FETCH target
|
# MDEV-12007 Allow ROW variables as a cursor FETCH target
|
||||||
|
@ -10026,6 +10026,25 @@ DROP PROCEDURE p1;
|
|||||||
DROP VIEW v1;
|
DROP VIEW v1;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # BUG#30366310: USING A FUNCTION TO ASSIGN DEFAULT VALUES TO
|
||||||
|
--echo # 2 OR MORE VARIABLES CRASHES SERVER
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
delimiter |;
|
||||||
|
create function f1() returns bigint return now()-1|
|
||||||
|
create procedure p1()
|
||||||
|
begin
|
||||||
|
declare b, c bigint default f1();
|
||||||
|
select b-c;
|
||||||
|
end|
|
||||||
|
call p1()|
|
||||||
|
drop procedure p1|
|
||||||
|
drop function f1|
|
||||||
|
delimiter ;|
|
||||||
|
|
||||||
|
|
||||||
--echo #End of 10.2 tests
|
--echo #End of 10.2 tests
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
|
@ -492,4 +492,12 @@ select * from mysql.plugin WHERE name='unexisting_udf';
|
|||||||
name dl
|
name dl
|
||||||
DROP FUNCTION unexisting_udf;
|
DROP FUNCTION unexisting_udf;
|
||||||
ERROR 42000: FUNCTION test.unexisting_udf does not exist
|
ERROR 42000: FUNCTION test.unexisting_udf does not exist
|
||||||
|
#
|
||||||
|
# Bug #31674599: THE UDF_INIT() FUNCTION CAUSE SERVER CRASH
|
||||||
|
#
|
||||||
|
call mtr.add_suppression('Invalid row in mysql.func table');
|
||||||
|
insert mysql.func () values ();
|
||||||
|
delete from mysql.func where name = '';
|
||||||
|
#
|
||||||
# End of 10.2 tests
|
# End of 10.2 tests
|
||||||
|
#
|
||||||
|
@ -562,4 +562,14 @@ select * from mysql.plugin WHERE name='unexisting_udf';
|
|||||||
--error ER_SP_DOES_NOT_EXIST
|
--error ER_SP_DOES_NOT_EXIST
|
||||||
DROP FUNCTION unexisting_udf;
|
DROP FUNCTION unexisting_udf;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # Bug #31674599: THE UDF_INIT() FUNCTION CAUSE SERVER CRASH
|
||||||
|
--echo #
|
||||||
|
call mtr.add_suppression('Invalid row in mysql.func table');
|
||||||
|
insert mysql.func () values ();
|
||||||
|
source include/restart_mysqld.inc;
|
||||||
|
delete from mysql.func where name = '';
|
||||||
|
|
||||||
|
--echo #
|
||||||
--echo # End of 10.2 tests
|
--echo # End of 10.2 tests
|
||||||
|
--echo #
|
||||||
|
@ -7125,7 +7125,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
000 000 000
|
000 000 000
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1264 Out of range value for column 'z' at row 1
|
Warning 1264 Out of range value for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7163,7 +7163,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
00000 00000 00000
|
00000 00000 00000
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1264 Out of range value for column 'z' at row 1
|
Warning 1264 Out of range value for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7201,7 +7201,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
00000000 00000000 00000000
|
00000000 00000000 00000000
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1264 Out of range value for column 'z' at row 1
|
Warning 1264 Out of range value for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7239,7 +7239,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
0000000000 0000000000 0000000000
|
0000000000 0000000000 0000000000
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1264 Out of range value for column 'z' at row 1
|
Warning 1264 Out of range value for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7277,7 +7277,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
00000000000000000000 00000000000000000000 00000000000000000000
|
00000000000000000000 00000000000000000000 00000000000000000000
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1264 Out of range value for column 'z' at row 1
|
Warning 1264 Out of range value for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7297,7 +7297,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
-9999999999 -9999999999 -9999999999
|
-9999999999 -9999999999 -9999999999
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1264 Out of range value for column 'z' at row 1
|
Warning 1264 Out of range value for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7308,7 +7308,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
0 0 0
|
0 0 0
|
||||||
Warnings:
|
Warnings:
|
||||||
Note 1265 Data truncated for column 'z' at row 1
|
Note 1265 Data truncated for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7319,7 +7319,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
0000000000 0000000000 0000000000
|
0000000000 0000000000 0000000000
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 1264 Out of range value for column 'z' at row 1
|
Warning 1264 Out of range value for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7330,7 +7330,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
0000000000 0000000000 0000000000
|
0000000000 0000000000 0000000000
|
||||||
Warnings:
|
Warnings:
|
||||||
Note 1265 Data truncated for column 'z' at row 1
|
Note 1265 Data truncated for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7341,7 +7341,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
0 0 0
|
0 0 0
|
||||||
Warnings:
|
Warnings:
|
||||||
Note 1265 Data truncated for column 'z' at row 1
|
Note 1265 Data truncated for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7352,7 +7352,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
0 0 0
|
0 0 0
|
||||||
Warnings:
|
Warnings:
|
||||||
Note 1265 Data truncated for column 'z' at row 1
|
Note 1265 Data truncated for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7363,7 +7363,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
0000000000 0000000000 0000000000
|
0000000000 0000000000 0000000000
|
||||||
Warnings:
|
Warnings:
|
||||||
Note 1265 Data truncated for column 'z' at row 1
|
Note 1265 Data truncated for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
@ -7374,7 +7374,7 @@ CALL sp1();
|
|||||||
x y z
|
x y z
|
||||||
0000000000 0000000000 0000000000
|
0000000000 0000000000 0000000000
|
||||||
Warnings:
|
Warnings:
|
||||||
Note 1265 Data truncated for column 'z' at row 1
|
Note 1265 Data truncated for column 'x' at row 1
|
||||||
DROP PROCEDURE IF EXISTS sp1;
|
DROP PROCEDURE IF EXISTS sp1;
|
||||||
CREATE PROCEDURE sp1( )
|
CREATE PROCEDURE sp1( )
|
||||||
BEGIN
|
BEGIN
|
||||||
|
22
mysql-test/suite/galera/r/galera_inject_bf_long_wait.result
Normal file
22
mysql-test/suite/galera/r/galera_inject_bf_long_wait.result
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
CREATE TABLE t1(id int not null primary key, b int) engine=InnoDB;
|
||||||
|
INSERT INTO t1 VALUES (0,0),(1,1),(2,2),(3,3);
|
||||||
|
BEGIN;
|
||||||
|
UPDATE t1 set b = 100 where id between 1 and 2;;
|
||||||
|
connect node_1b, 127.0.0.1, root, , test, $NODE_MYPORT_1;
|
||||||
|
connection node_1b;
|
||||||
|
SET @save_dbug = @@SESSION.debug_dbug;
|
||||||
|
SET @@SESSION.innodb_lock_wait_timeout=2;
|
||||||
|
SET @@SESSION.debug_dbug = '+d,wsrep_instrument_BF_lock_wait';
|
||||||
|
UPDATE t1 set b = 200 WHERE id = 1;
|
||||||
|
ERROR HY000: Lock wait timeout exceeded; try restarting transaction
|
||||||
|
SET @@SESSION.debug_dbug = @save_dbug;
|
||||||
|
connection node_1;
|
||||||
|
COMMIT;
|
||||||
|
SELECT * FROM t1;
|
||||||
|
id b
|
||||||
|
0 0
|
||||||
|
1 100
|
||||||
|
2 100
|
||||||
|
3 3
|
||||||
|
disconnect node_1b;
|
||||||
|
DROP TABLE t1;
|
19
mysql-test/suite/galera/r/galera_password.result
Normal file
19
mysql-test/suite/galera/r/galera_password.result
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
SHOW VARIABLES LIKE '%password%';
|
||||||
|
Variable_name Value
|
||||||
|
old_passwords OFF
|
||||||
|
report_password
|
||||||
|
strict_password_validation ON
|
||||||
|
CREATE USER 'user123456'@'localhost';
|
||||||
|
GRANT SELECT, INSERT, UPDATE ON test.* TO 'user123456'@'localhost';
|
||||||
|
SET PASSWORD FOR 'user123456'@'localhost' = PASSWORD('A$10abcdDCBA123456%7');
|
||||||
|
SHOW GRANTS FOR 'user123456'@'localhost';
|
||||||
|
Grants for user123456@localhost
|
||||||
|
GRANT USAGE ON *.* TO `user123456`@`localhost` IDENTIFIED BY PASSWORD '*5846CF4D641598B360B3562E581586155C59F65A'
|
||||||
|
GRANT SELECT, INSERT, UPDATE ON `test`.* TO `user123456`@`localhost`
|
||||||
|
connection node_2;
|
||||||
|
SHOW GRANTS FOR 'user123456'@'localhost';
|
||||||
|
Grants for user123456@localhost
|
||||||
|
GRANT USAGE ON *.* TO `user123456`@`localhost` IDENTIFIED BY PASSWORD '*5846CF4D641598B360B3562E581586155C59F65A'
|
||||||
|
GRANT SELECT, INSERT, UPDATE ON `test`.* TO `user123456`@`localhost`
|
||||||
|
connection node_1;
|
||||||
|
DROP USER 'user123456'@'localhost';
|
@ -1,6 +1,6 @@
|
|||||||
SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
SELECT VARIABLE_VALUE AS EXPECT_4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
VARIABLE_VALUE = 4
|
EXPECT_4
|
||||||
1
|
4
|
||||||
connection node_1;
|
connection node_1;
|
||||||
CREATE TABLE t1 (f1 INTEGER);
|
CREATE TABLE t1 (f1 INTEGER);
|
||||||
INSERT INTO t1 VALUES (1);
|
INSERT INTO t1 VALUES (1);
|
||||||
@ -46,30 +46,30 @@ INSERT INTO t1 VALUES (33);
|
|||||||
connection node_4;
|
connection node_4;
|
||||||
INSERT INTO t1 VALUES (341);
|
INSERT INTO t1 VALUES (341);
|
||||||
connection node_1;
|
connection node_1;
|
||||||
SELECT COUNT(*) = 19 FROM t1;
|
SELECT COUNT(*) AS EXPECT_19 FROM t1;
|
||||||
COUNT(*) = 19
|
EXPECT_19
|
||||||
1
|
19
|
||||||
connection node_2;
|
connection node_2;
|
||||||
SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
SELECT VARIABLE_VALUE AS EXPECT_4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
VARIABLE_VALUE = 4
|
EXPECT_4
|
||||||
1
|
4
|
||||||
SELECT COUNT(*) = 19 FROM t1;
|
SELECT COUNT(*) AS EXPECT_19 FROM t1;
|
||||||
COUNT(*) = 19
|
EXPECT_19
|
||||||
1
|
19
|
||||||
connection node_3;
|
connection node_3;
|
||||||
SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
SELECT VARIABLE_VALUE AS EXPECT_4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
VARIABLE_VALUE = 4
|
EXPECT_4
|
||||||
1
|
4
|
||||||
SELECT COUNT(*) = 19 FROM t1;
|
SELECT COUNT(*) AS EXPECT_19 FROM t1;
|
||||||
COUNT(*) = 19
|
EXPECT_19
|
||||||
1
|
19
|
||||||
connection node_4;
|
connection node_4;
|
||||||
SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
SELECT VARIABLE_VALUE AS EXPECT_4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
VARIABLE_VALUE = 4
|
EXPECT_4
|
||||||
1
|
4
|
||||||
SELECT COUNT(*) = 19 FROM t1;
|
SELECT COUNT(*) AS EXPECT_19 FROM t1;
|
||||||
COUNT(*) = 19
|
EXPECT_19
|
||||||
1
|
19
|
||||||
connection node_1;
|
connection node_1;
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
CALL mtr.add_suppression("There are no nodes in the same segment that will ever be able to become donors, yet there is a suitable donor outside");
|
CALL mtr.add_suppression("There are no nodes in the same segment that will ever be able to become donors, yet there is a suitable donor outside");
|
||||||
|
25
mysql-test/suite/galera/t/galera_inject_bf_long_wait.test
Normal file
25
mysql-test/suite/galera/t/galera_inject_bf_long_wait.test
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
--source include/galera_cluster.inc
|
||||||
|
--source include/have_debug.inc
|
||||||
|
--source include/have_debug_sync.inc
|
||||||
|
|
||||||
|
CREATE TABLE t1(id int not null primary key, b int) engine=InnoDB;
|
||||||
|
INSERT INTO t1 VALUES (0,0),(1,1),(2,2),(3,3);
|
||||||
|
|
||||||
|
BEGIN;
|
||||||
|
--send UPDATE t1 set b = 100 where id between 1 and 2;
|
||||||
|
|
||||||
|
--connect node_1b, 127.0.0.1, root, , test, $NODE_MYPORT_1
|
||||||
|
--connection node_1b
|
||||||
|
SET @save_dbug = @@SESSION.debug_dbug;
|
||||||
|
SET @@SESSION.innodb_lock_wait_timeout=2;
|
||||||
|
SET @@SESSION.debug_dbug = '+d,wsrep_instrument_BF_lock_wait';
|
||||||
|
--error ER_LOCK_WAIT_TIMEOUT
|
||||||
|
UPDATE t1 set b = 200 WHERE id = 1;
|
||||||
|
SET @@SESSION.debug_dbug = @save_dbug;
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
--reap
|
||||||
|
COMMIT;
|
||||||
|
SELECT * FROM t1;
|
||||||
|
--disconnect node_1b
|
||||||
|
DROP TABLE t1;
|
14
mysql-test/suite/galera/t/galera_password.test
Normal file
14
mysql-test/suite/galera/t/galera_password.test
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
--source include/galera_cluster.inc
|
||||||
|
|
||||||
|
SHOW VARIABLES LIKE '%password%';
|
||||||
|
|
||||||
|
CREATE USER 'user123456'@'localhost';
|
||||||
|
GRANT SELECT, INSERT, UPDATE ON test.* TO 'user123456'@'localhost';
|
||||||
|
SET PASSWORD FOR 'user123456'@'localhost' = PASSWORD('A$10abcdDCBA123456%7');
|
||||||
|
SHOW GRANTS FOR 'user123456'@'localhost';
|
||||||
|
|
||||||
|
--connection node_2
|
||||||
|
SHOW GRANTS FOR 'user123456'@'localhost';
|
||||||
|
|
||||||
|
--connection node_1
|
||||||
|
DROP USER 'user123456'@'localhost';
|
@ -10,9 +10,11 @@
|
|||||||
|
|
||||||
--source include/big_test.inc
|
--source include/big_test.inc
|
||||||
--source include/galera_cluster.inc
|
--source include/galera_cluster.inc
|
||||||
--source include/have_innodb.inc
|
--source include/force_restart.inc
|
||||||
|
|
||||||
SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
--let $wait_condition = SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
SELECT VARIABLE_VALUE AS EXPECT_4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
|
|
||||||
--connection node_1
|
--connection node_1
|
||||||
CREATE TABLE t1 (f1 INTEGER);
|
CREATE TABLE t1 (f1 INTEGER);
|
||||||
@ -37,10 +39,11 @@ INSERT INTO t1 VALUES (4);
|
|||||||
INSERT INTO t1 VALUES (13);
|
INSERT INTO t1 VALUES (13);
|
||||||
|
|
||||||
--source include/kill_galera.inc
|
--source include/kill_galera.inc
|
||||||
--sleep 5
|
|
||||||
|
|
||||||
--connection node_1
|
--connection node_1
|
||||||
--source include/wait_until_connected_again.inc
|
--source include/wait_until_connected_again.inc
|
||||||
|
--let $wait_condition = SELECT VARIABLE_VALUE = 3 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
|
--source include/wait_condition.inc
|
||||||
INSERT INTO t1 VALUES (11);
|
INSERT INTO t1 VALUES (11);
|
||||||
|
|
||||||
--connection node_2
|
--connection node_2
|
||||||
@ -51,9 +54,11 @@ INSERT INTO t1 VALUES (14);
|
|||||||
|
|
||||||
--connection node_3
|
--connection node_3
|
||||||
--source include/start_mysqld.inc
|
--source include/start_mysqld.inc
|
||||||
--sleep 5
|
|
||||||
--source include/wait_until_connected_again.inc
|
--source include/wait_until_connected_again.inc
|
||||||
|
|
||||||
|
--let $wait_condition = SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
INSERT INTO t1 VALUES (131);
|
INSERT INTO t1 VALUES (131);
|
||||||
|
|
||||||
#
|
#
|
||||||
@ -64,10 +69,12 @@ INSERT INTO t1 VALUES (131);
|
|||||||
INSERT INTO t1 VALUES (22);
|
INSERT INTO t1 VALUES (22);
|
||||||
|
|
||||||
--source include/kill_galera.inc
|
--source include/kill_galera.inc
|
||||||
--sleep 5
|
|
||||||
|
|
||||||
--connection node_1
|
--connection node_1
|
||||||
--source include/wait_until_connected_again.inc
|
--source include/wait_until_connected_again.inc
|
||||||
|
--let $wait_condition = SELECT VARIABLE_VALUE = 3 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
INSERT INTO t1 VALUES (21);
|
INSERT INTO t1 VALUES (21);
|
||||||
|
|
||||||
--connection node_3
|
--connection node_3
|
||||||
@ -78,8 +85,9 @@ INSERT INTO t1 VALUES (24);
|
|||||||
|
|
||||||
--connection node_2
|
--connection node_2
|
||||||
--source include/start_mysqld.inc
|
--source include/start_mysqld.inc
|
||||||
--sleep 5
|
|
||||||
--source include/wait_until_connected_again.inc
|
--source include/wait_until_connected_again.inc
|
||||||
|
--let $wait_condition = SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
INSERT INTO t1 VALUES (221);
|
INSERT INTO t1 VALUES (221);
|
||||||
|
|
||||||
@ -91,10 +99,11 @@ INSERT INTO t1 VALUES (221);
|
|||||||
INSERT INTO t1 VALUES (34);
|
INSERT INTO t1 VALUES (34);
|
||||||
|
|
||||||
--source include/kill_galera.inc
|
--source include/kill_galera.inc
|
||||||
--sleep 5
|
|
||||||
|
|
||||||
--connection node_1
|
--connection node_1
|
||||||
--source include/wait_until_connected_again.inc
|
--source include/wait_until_connected_again.inc
|
||||||
|
--let $wait_condition = SELECT VARIABLE_VALUE = 3 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
|
--source include/wait_condition.inc
|
||||||
INSERT INTO t1 VALUES (31);
|
INSERT INTO t1 VALUES (31);
|
||||||
|
|
||||||
--connection node_2
|
--connection node_2
|
||||||
@ -105,8 +114,9 @@ INSERT INTO t1 VALUES (33);
|
|||||||
|
|
||||||
--connection node_4
|
--connection node_4
|
||||||
--source include/start_mysqld.inc
|
--source include/start_mysqld.inc
|
||||||
--sleep 5
|
|
||||||
--source include/wait_until_connected_again.inc
|
--source include/wait_until_connected_again.inc
|
||||||
|
--let $wait_condition = SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
INSERT INTO t1 VALUES (341);
|
INSERT INTO t1 VALUES (341);
|
||||||
|
|
||||||
@ -119,19 +129,19 @@ INSERT INTO t1 VALUES (341);
|
|||||||
--let $wait_condition = SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
--let $wait_condition = SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
--source include/wait_condition.inc
|
--source include/wait_condition.inc
|
||||||
|
|
||||||
SELECT COUNT(*) = 19 FROM t1;
|
SELECT COUNT(*) AS EXPECT_19 FROM t1;
|
||||||
|
|
||||||
--connection node_2
|
--connection node_2
|
||||||
SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
SELECT VARIABLE_VALUE AS EXPECT_4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
SELECT COUNT(*) = 19 FROM t1;
|
SELECT COUNT(*) AS EXPECT_19 FROM t1;
|
||||||
|
|
||||||
--connection node_3
|
--connection node_3
|
||||||
SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
SELECT VARIABLE_VALUE AS EXPECT_4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
SELECT COUNT(*) = 19 FROM t1;
|
SELECT COUNT(*) AS EXPECT_19 FROM t1;
|
||||||
|
|
||||||
--connection node_4
|
--connection node_4
|
||||||
SELECT VARIABLE_VALUE = 4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
SELECT VARIABLE_VALUE AS EXPECT_4 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';
|
||||||
SELECT COUNT(*) = 19 FROM t1;
|
SELECT COUNT(*) AS EXPECT_19 FROM t1;
|
||||||
|
|
||||||
--connection node_1
|
--connection node_1
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
@ -809,4 +809,12 @@ eval LOAD DATA INFILE '$MYSQLTEST_VARDIR/tmp/load.data' REPLACE INTO TABLE t1 (p
|
|||||||
|
|
||||||
--remove_file $MYSQLTEST_VARDIR/tmp/load.data
|
--remove_file $MYSQLTEST_VARDIR/tmp/load.data
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
--echo # MDEV-19011 Assertion `file->s->base.reclength < file->s->vreclength'
|
||||||
|
--echo # failed in ha_myisam::setup_vcols_for_repair
|
||||||
|
CREATE TABLE t1 (a INT GENERATED ALWAYS AS (1) VIRTUAL) ENGINE=MyISAM;
|
||||||
|
ALTER TABLE t1 ADD KEY (a);
|
||||||
|
|
||||||
|
DROP TABLE t1;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -669,3 +669,77 @@ PRIMARY KEY (number)
|
|||||||
REPLACE t2(number) VALUES('1');
|
REPLACE t2(number) VALUES('1');
|
||||||
REPLACE t2(number) VALUES('1');
|
REPLACE t2(number) VALUES('1');
|
||||||
DROP TABLE t2;
|
DROP TABLE t2;
|
||||||
|
# MDEV-24583 SELECT aborts after failed REPLACE into table with vcol
|
||||||
|
CREATE TABLE t1 (pk INT, a VARCHAR(3), v VARCHAR(3) AS (CONCAT('x-',a)),
|
||||||
|
PRIMARY KEY(pk)) ENGINE=MyISAM;
|
||||||
|
CREATE VIEW v1 AS SELECT * FROM t1;
|
||||||
|
INSERT INTO t1 (pk, a) VALUES (1,'foo');
|
||||||
|
SET sql_mode=CONCAT(@@sql_mode,',STRICT_ALL_TABLES');
|
||||||
|
REPLACE INTO t1 (pk,a) VALUES (1,'qux');
|
||||||
|
SELECT * FROM v1;
|
||||||
|
pk a v
|
||||||
|
1 foo x-f
|
||||||
|
DROP VIEW v1;
|
||||||
|
DROP TABLE t1;
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
pk INT,
|
||||||
|
a VARCHAR(1),
|
||||||
|
v VARCHAR(1) AS (CONCAT('virt-',a)) VIRTUAL,
|
||||||
|
PRIMARY KEY (pk)
|
||||||
|
) ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 (pk,a) VALUES
|
||||||
|
(1,'a'),(2,'b'),(3,'c'),(4,'d'),(5,'e'),(6,'f');
|
||||||
|
REPLACE INTO t1 (pk) VALUES (1);
|
||||||
|
ERROR 22001: Data too long for column 'v' at row 1
|
||||||
|
SELECT * FROM t1 ORDER BY a;
|
||||||
|
pk a v
|
||||||
|
1 a v
|
||||||
|
2 b v
|
||||||
|
3 c v
|
||||||
|
4 d v
|
||||||
|
5 e v
|
||||||
|
6 f v
|
||||||
|
SET SQL_MODE=DEFAULT;
|
||||||
|
DROP TABLE t1;
|
||||||
|
# (duplicate) MDEV-24656
|
||||||
|
# [FATAL] InnoDB: Data field type 0, len 0, ASAN heap-buffer-overflow
|
||||||
|
# upon LOAD DATA with virtual columns
|
||||||
|
CREATE TABLE t1 (id INT PRIMARY KEY, a VARCHAR(2333),
|
||||||
|
va VARCHAR(171) AS (a)) ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 (id,a) VALUES (1,REPEAT('x',200));
|
||||||
|
SELECT id, va INTO OUTFILE 'load_t1' FROM t1;
|
||||||
|
LOAD DATA INFILE 'load_t1' REPLACE INTO TABLE t1 (id,va);
|
||||||
|
ERROR 22001: Data too long for column 'va' at row 1
|
||||||
|
SELECT * FROM t1;
|
||||||
|
id a va
|
||||||
|
1 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
||||||
|
LOAD DATA INFILE 'load_t1' IGNORE INTO TABLE t1 (id,va);
|
||||||
|
Warnings:
|
||||||
|
Warning 1062 Duplicate entry '1' for key 'PRIMARY'
|
||||||
|
DROP TABLE t1;
|
||||||
|
CREATE TABLE t1 (id BIGINT PRIMARY KEY, a VARCHAR(2333),
|
||||||
|
va VARCHAR(171) AS (a)) ENGINE=InnoDB;
|
||||||
|
INSERT INTO t1 (id,a) VALUES (1,REPEAT('x',200));
|
||||||
|
SELECT id, va INTO OUTFILE 'load_t1' FROM t1;
|
||||||
|
LOAD DATA INFILE 'load_t1' REPLACE INTO TABLE t1 (id,va);
|
||||||
|
ERROR 22001: Data too long for column 'va' at row 1
|
||||||
|
SELECT * FROM t1;
|
||||||
|
id a va
|
||||||
|
1 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
||||||
|
LOAD DATA INFILE 'load_t1' IGNORE INTO TABLE t1 (id,va);
|
||||||
|
Warnings:
|
||||||
|
Warning 1062 Duplicate entry '1' for key 'PRIMARY'
|
||||||
|
DROP TABLE t1;
|
||||||
|
# (duplicate) MDEV-24665
|
||||||
|
# ASAN errors, assertion failures, corrupt values after failed
|
||||||
|
# LOAD DATA into table with virtual/stored column
|
||||||
|
CREATE TABLE t1 (id INT PRIMARY KEY,
|
||||||
|
ts TIMESTAMP DEFAULT '1971-01-01 00:00:00',
|
||||||
|
c VARBINARY(8) DEFAULT '', vc VARCHAR(3) AS (c) STORED);
|
||||||
|
INSERT IGNORE INTO t1 (id,c) VALUES (1,'foobar');
|
||||||
|
Warnings:
|
||||||
|
Warning 1265 Data truncated for column 'vc' at row 1
|
||||||
|
SELECT id, ts, vc INTO OUTFILE 'load_t1' FROM t1;
|
||||||
|
LOAD DATA INFILE 'load_t1' REPLACE INTO TABLE t1 (id, ts, vc);
|
||||||
|
INSERT IGNORE INTO t1 (id) VALUES (2);
|
||||||
|
DROP TABLE t1;
|
||||||
|
@ -877,6 +877,11 @@ Warning 1264 Out of range value for column 'vi' at row 1
|
|||||||
LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/load.data' REPLACE INTO TABLE t1 (pk,i,ts);
|
LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/load.data' REPLACE INTO TABLE t1 (pk,i,ts);
|
||||||
ERROR 22003: Out of range value for column 'vi' at row 1
|
ERROR 22003: Out of range value for column 'vi' at row 1
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
# MDEV-19011 Assertion `file->s->base.reclength < file->s->vreclength'
|
||||||
|
# failed in ha_myisam::setup_vcols_for_repair
|
||||||
|
CREATE TABLE t1 (a INT GENERATED ALWAYS AS (1) VIRTUAL) ENGINE=MyISAM;
|
||||||
|
ALTER TABLE t1 ADD KEY (a);
|
||||||
|
DROP TABLE t1;
|
||||||
#
|
#
|
||||||
# BUG#21365158 WL8149:ASSERTION `!TABLE || (!TABLE->WRITE_SET
|
# BUG#21365158 WL8149:ASSERTION `!TABLE || (!TABLE->WRITE_SET
|
||||||
#
|
#
|
||||||
|
@ -877,6 +877,11 @@ Warning 1264 Out of range value for column 'vi' at row 1
|
|||||||
LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/load.data' REPLACE INTO TABLE t1 (pk,i,ts);
|
LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/load.data' REPLACE INTO TABLE t1 (pk,i,ts);
|
||||||
ERROR 22003: Out of range value for column 'vi' at row 1
|
ERROR 22003: Out of range value for column 'vi' at row 1
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
|
# MDEV-19011 Assertion `file->s->base.reclength < file->s->vreclength'
|
||||||
|
# failed in ha_myisam::setup_vcols_for_repair
|
||||||
|
CREATE TABLE t1 (a INT GENERATED ALWAYS AS (1) VIRTUAL) ENGINE=MyISAM;
|
||||||
|
ALTER TABLE t1 ADD KEY (a);
|
||||||
|
DROP TABLE t1;
|
||||||
DROP VIEW IF EXISTS v1,v2;
|
DROP VIEW IF EXISTS v1,v2;
|
||||||
DROP TABLE IF EXISTS t1,t2,t3;
|
DROP TABLE IF EXISTS t1,t2,t3;
|
||||||
DROP PROCEDURE IF EXISTS p1;
|
DROP PROCEDURE IF EXISTS p1;
|
||||||
|
@ -233,4 +233,76 @@ set debug_sync= "now WAIT_FOR got_no_such_table";
|
|||||||
set global debug_dbug= @saved_dbug;
|
set global debug_dbug= @saved_dbug;
|
||||||
drop table t1;
|
drop table t1;
|
||||||
set debug_sync=reset;
|
set debug_sync=reset;
|
||||||
|
#
|
||||||
|
# MDEV-18546 ASAN heap-use-after-free
|
||||||
|
# in innobase_get_computed_value / row_purge
|
||||||
|
#
|
||||||
|
CREATE TABLE t1 (
|
||||||
|
pk INT AUTO_INCREMENT,
|
||||||
|
b BIT(15),
|
||||||
|
v BIT(15) AS (b) VIRTUAL,
|
||||||
|
PRIMARY KEY(pk),
|
||||||
|
UNIQUE(v)
|
||||||
|
) ENGINE=InnoDB;
|
||||||
|
INSERT IGNORE INTO t1 (b) VALUES
|
||||||
|
(NULL),(b'011'),(b'000110100'),
|
||||||
|
(b'01101101010'),(b'01111001001011'),(NULL);
|
||||||
|
SET GLOBAL innodb_debug_sync = "ib_clust_v_col_before_row_allocated "
|
||||||
|
"SIGNAL before_row_allocated "
|
||||||
|
"WAIT_FOR flush_unlock";
|
||||||
|
SET GLOBAL innodb_debug_sync = "ib_open_after_dict_open "
|
||||||
|
"SIGNAL purge_open "
|
||||||
|
"WAIT_FOR select_open";
|
||||||
|
set global debug_dbug= "d,ib_purge_virtual_index_callback";
|
||||||
|
connect purge_waiter,localhost,root;
|
||||||
|
SET debug_sync= "now WAIT_FOR before_row_allocated";
|
||||||
|
connection default;
|
||||||
|
REPLACE INTO t1 (pk, b) SELECT pk, b FROM t1;
|
||||||
|
connection purge_waiter;
|
||||||
|
connection default;
|
||||||
|
disconnect purge_waiter;
|
||||||
|
FLUSH TABLES;
|
||||||
|
SET GLOBAL innodb_debug_sync = reset;
|
||||||
|
SET debug_sync= "now SIGNAL flush_unlock WAIT_FOR purge_open";
|
||||||
|
SET GLOBAL innodb_debug_sync = reset;
|
||||||
|
SET debug_sync= "ib_open_after_dict_open SIGNAL select_open";
|
||||||
|
SELECT * FROM t1;
|
||||||
|
pk b v
|
||||||
|
1 NULL NULL
|
||||||
|
2 |