summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorChad MILLER <chad@mysql.com>2009-03-10 12:53:43 -0400
committerChad MILLER <chad@mysql.com>2009-03-10 12:53:43 -0400
commit6b72857803d50d1090e6fa514b0ddee81234fab7 (patch)
tree655a7177f798d31a69575ff2dd51a51e575aecb5 /mysql-test
parent1c39d5ff8fa695573907505996b6c09e7d3d1261 (diff)
parent0d9589a433a1473e91e446fb842f788e5e1ff2c3 (diff)
downloadmariadb-git-6b72857803d50d1090e6fa514b0ddee81234fab7.tar.gz
Merge from bugfix tree.
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/mysqldump.result54
-rw-r--r--mysql-test/t/mysqldump.test14
2 files changed, 68 insertions, 0 deletions
diff --git a/mysql-test/r/mysqldump.result b/mysql-test/r/mysqldump.result
index 49430a5c62d..1897a7df799 100644
--- a/mysql-test/r/mysqldump.result
+++ b/mysql-test/r/mysqldump.result
@@ -3559,6 +3559,60 @@ DROP TABLE t1,t2;
-- Dump completed on DATE
SET @@GLOBAL.CONCURRENT_INSERT = @OLD_CONCURRENT_INSERT;
#
+# Bug #42635: mysqldump includes views that were excluded using
+# the --ignore-table option
+#
+create database db42635;
+use db42635;
+create table t1 (id int);
+create view db42635.v1 (c) as select * from db42635.t1;
+create view db42635.v2 (c) as select * from db42635.t1;
+
+/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
+/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
+/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
+/*!40101 SET NAMES utf8 */;
+/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
+/*!40103 SET TIME_ZONE='+00:00' */;
+/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
+/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
+/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
+/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
+DROP TABLE IF EXISTS `t1`;
+/*!40101 SET @saved_cs_client = @@character_set_client */;
+/*!40101 SET character_set_client = utf8 */;
+CREATE TABLE `t1` (
+ `id` int(11) default NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1;
+/*!40101 SET character_set_client = @saved_cs_client */;
+
+LOCK TABLES `t1` WRITE;
+/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
+/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
+UNLOCK TABLES;
+DROP TABLE IF EXISTS `v2`;
+/*!50001 DROP VIEW IF EXISTS `v2`*/;
+/*!50001 CREATE TABLE `v2` (
+ `c` int(11)
+) ENGINE=MyISAM */;
+/*!50001 DROP TABLE `v2`*/;
+/*!50001 DROP VIEW IF EXISTS `v2`*/;
+/*!50001 CREATE ALGORITHM=UNDEFINED */
+/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
+/*!50001 VIEW `v2` AS select `t1`.`id` AS `c` from `t1` */;
+/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
+
+/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
+/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
+/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
+/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
+/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
+/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
+/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
+
+use test;
+drop database db42635;
+#
# Bug#33550 mysqldump 4.0 compatibility broken
#
SET NAMES utf8;
diff --git a/mysql-test/t/mysqldump.test b/mysql-test/t/mysqldump.test
index f252e65c74c..52eecc62931 100644
--- a/mysql-test/t/mysqldump.test
+++ b/mysql-test/t/mysqldump.test
@@ -1649,6 +1649,20 @@ DROP TABLE t1,t2;
# We reset concurrent_inserts value to whatever it was at the start of the test
SET @@GLOBAL.CONCURRENT_INSERT = @OLD_CONCURRENT_INSERT;
+--echo #
+--echo # Bug #42635: mysqldump includes views that were excluded using
+--echo # the --ignore-table option
+--echo #
+
+create database db42635;
+use db42635;
+create table t1 (id int);
+create view db42635.v1 (c) as select * from db42635.t1;
+create view db42635.v2 (c) as select * from db42635.t1;
+--exec $MYSQL_DUMP --skip-comments --ignore-table=db42635.v1 db42635
+use test;
+drop database db42635;
+
--echo #
--echo # Bug#33550 mysqldump 4.0 compatibility broken