diff options
author | Sergei Golubchik <serg@mariadb.org> | 2017-05-09 13:24:52 +0200 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2017-05-09 13:24:52 +0200 |
commit | c91ecf9e9bebf3cf2dafbd3193de4df94be09870 (patch) | |
tree | a9ab429c8e8a6a50c38557cbdd38d9612480f49c /mysql-test/t/mysqldump.test | |
parent | 2645bda5f20ab10bc26dc1cb69f91b5505c1faae (diff) | |
parent | c92168fcd26aad35bd4cb5d65175e3545133f201 (diff) | |
download | mariadb-git-c91ecf9e9bebf3cf2dafbd3193de4df94be09870.tar.gz |
Merge branch '10.1' into 10.2
Revert commit db0917f68f, because the fix for MDEV-12696
is coming from 5.5 and 10.1 in this merge.
Diffstat (limited to 'mysql-test/t/mysqldump.test')
-rw-r--r-- | mysql-test/t/mysqldump.test | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/mysql-test/t/mysqldump.test b/mysql-test/t/mysqldump.test index 6d4e0e3f2b9..9f74f4ad9c0 100644 --- a/mysql-test/t/mysqldump.test +++ b/mysql-test/t/mysqldump.test @@ -2490,6 +2490,58 @@ DROP TABLE t2; DROP DATABASE db_20772273; USE test; +--echo # +--echo # Bug #25717383: MYSQLDUMP MAY EXECUTE ANY ARBITRARY QUERY +--echo # + + +CREATE DATABASE bug25717383; +use bug25717383; + +CREATE TABLE `tab +one` (a int); +CREATE VIEW `view +one` as SELECT * FROM `tab +one`; + +CREATE PROCEDURE `proc +one`() SELECT * from `tab +one`; + +CREATE TEMPORARY TABLE `temp +one` (id INT); + +CREATE TRIGGER `trig +one` BEFORE INSERT ON `tab +one` FOR EACH ROW SET NEW.a = 1; + +CREATE EVENT `event +one` ON SCHEDULE AT '2030-01-01 00:00:00' DO SET @a=5; + +SHOW TABLES FROM bug25717383; +--replace_column 6 # +SHOW TRIGGERS FROM bug25717383; +--replace_column 6 # +SHOW EVENTS FROM bug25717383; + +SELECT ROUTINE_NAME FROM INFORMATION_SCHEMA.ROUTINES + WHERE ROUTINE_SCHEMA='bug25717383' AND ROUTINE_TYPE= 'PROCEDURE' + ORDER BY ROUTINE_NAME; + +--exec $MYSQL_DUMP --triggers --events --routines --add-drop-database --databases bug25717383 > $MYSQLTEST_VARDIR/tmp/bug25717383.sql + +SHOW TABLES FROM bug25717383; +--replace_column 6 # +SHOW TRIGGERS FROM bug25717383; +--replace_column 6 # +SHOW EVENTS FROM bug25717383; + +SELECT ROUTINE_NAME FROM INFORMATION_SCHEMA.ROUTINES + WHERE ROUTINE_SCHEMA='bug25717383' AND ROUTINE_TYPE= 'PROCEDURE' + ORDER BY ROUTINE_NAME; + +DROP DATABASE bug25717383; + # # MDEV-6091 mysqldump goes in a loop and segfaults if --dump-slave is specified and it cannot connect to the server # |