summaryrefslogtreecommitdiff
path: root/mysql-test/t/mysqldump.test
diff options
context:
space:
mode:
authorunknown <iggy@recycle.(none)>2007-03-29 10:42:03 -0400
committerunknown <iggy@recycle.(none)>2007-03-29 10:42:03 -0400
commit1edf36853b8ce2c4a3e5a3b2676445baef60b50f (patch)
treee03c95e78f3d23c4b7429b3b50374f9a08f7eea6 /mysql-test/t/mysqldump.test
parent9e6d54e4a5ddf0aae5b23a9b51507e7bb6b5d5f5 (diff)
parent609277f942e5479976d5a1f31da55fd2cf646109 (diff)
downloadmariadb-git-1edf36853b8ce2c4a3e5a3b2676445baef60b50f.tar.gz
Merge recycle.(none):/src/bug23491/my50-bug23491
into recycle.(none):/src/bug23491/my51-bug23491 mysql-test/r/information_schema.result: Auto merged mysql-test/r/sp-code.result: Auto merged mysql-test/r/udf.result: Auto merged mysql-test/t/mysqldump.test: Auto merged sql/item_func.cc: Auto merged sql/sp.cc: Auto merged sql/sp_head.h: Auto merged mysql-test/r/mysqldump.result: Manual Merge. sql/sql_yacc.yy: Manual Merge.
Diffstat (limited to 'mysql-test/t/mysqldump.test')
-rw-r--r--mysql-test/t/mysqldump.test32
1 files changed, 32 insertions, 0 deletions
diff --git a/mysql-test/t/mysqldump.test b/mysql-test/t/mysqldump.test
index d9372ad35c1..bb33f00b8e5 100644
--- a/mysql-test/t/mysqldump.test
+++ b/mysql-test/t/mysqldump.test
@@ -1432,6 +1432,38 @@ INSERT INTO t1 VALUES(1,0xff00fef0);
DROP TABLE t1;
--echo #
+--echo # Bug #23491: MySQLDump prefix function call in a view by database name
+--echo #
+
+# Setup
+create database bug23491_original;
+create database bug23491_restore;
+use bug23491_original;
+create table t1 (c1 int);
+create view v1 as select * from t1;
+create procedure p1() select 1;
+create function f1() returns int return 1;
+create view v2 as select f1();
+create function f2() returns int return f1();
+create view v3 as select bug23491_original.f1();
+
+# Backup.
+--exec $MYSQL_DUMP --skip-comments -uroot --opt --routines bug23491_original > $MYSQLTEST_VARDIR/tmp/bug23491_backup.sql;
+
+# Restore.
+--exec $MYSQL bug23491_restore < $MYSQLTEST_VARDIR/tmp/bug23491_backup.sql;
+
+# Verify
+use bug23491_restore;
+show create view bug23491_restore.v2;
+show create view bug23491_restore.v3;
+
+# Cleanup
+drop database bug23491_original;
+drop database bug23491_restore;
+use test;
+
+--echo #
--echo # End of 5.0 tests
--echo #