diff options
author | unknown <cmiller@zippy.cornsilk.net> | 2008-03-12 12:40:12 -0400 |
---|---|---|
committer | unknown <cmiller@zippy.cornsilk.net> | 2008-03-12 12:40:12 -0400 |
commit | b5978a9424c6213a8282713feb3734c2f92968c8 (patch) | |
tree | d15b0cd2f289b1d23496c2ae018b858b23abb8a2 /mysql-test/r/drop.result | |
parent | b2a68038cecdd9881ef420fcbe984acfaa934b7a (diff) | |
download | mariadb-git-b5978a9424c6213a8282713feb3734c2f92968c8.tar.gz |
Bug#26703: DROP DATABASE fails if database contains a #mysql50# \
table with backticks
(Thanks to Lu Jingdong, though I did not take his patch directly, as
it contained a significant flaw.)
It wasn't a backtick/parsing problem. We merely didn't anticipate
and allocate enough space to handle the optional "#mysql50#" table-
name prefix.
Now, allocate that extra space in case we need it when we look up
a legacy table to get its file's name.
mysql-test/r/drop.result:
Verify that databases with old-style files can be removed.
mysql-test/t/drop.test:
Verify that databases with old-style files can be removed.
sql/sql_db.cc:
Extend the size of the memory that holds the table's name, so that
the legacy "mysql50" prefix fits.
Diffstat (limited to 'mysql-test/r/drop.result')
-rw-r--r-- | mysql-test/r/drop.result | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/mysql-test/r/drop.result b/mysql-test/r/drop.result index 71d6fcc7cd0..03445c51e38 100644 --- a/mysql-test/r/drop.result +++ b/mysql-test/r/drop.result @@ -91,4 +91,15 @@ create table mysql_test.`#sql-347f_7` (f1 int); create table mysql_test.`#sql-347f_8` (f1 int); drop table mysql_test.`#sql-347f_8`; drop database mysql_test; +create database mysqltestbug26703; +use mysqltestbug26703; +create table `#mysql50#abc``def` ( id int ); +create table `aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa` (a int); +ERROR 42000: Incorrect table name 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' +create table `aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa` (a int); +create table `#mysql50#aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa` (a int); +create table `#mysql50#aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa` (a int); +ERROR 42000: Incorrect table name '#mysql50#aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' +use test; +drop database mysqltestbug26703; End of 5.1 tests |