diff options
author | unknown <ingo@mysql.com> | 2005-06-01 11:15:21 +0200 |
---|---|---|
committer | unknown <ingo@mysql.com> | 2005-06-01 11:15:21 +0200 |
commit | 19788d383067f7e08f9080ff4d941bdd8f832757 (patch) | |
tree | 7a8b8f55be2cc9a973bed05c6c890d7d4cd3ca38 /mysql-test | |
parent | 99db091f4e957a64ec12110b1bfa31b75a7bb8a4 (diff) | |
parent | e5755ffe4d0e7d9020ddd3c0f23b7474a013dfd2 (diff) | |
download | mariadb-git-19788d383067f7e08f9080ff4d941bdd8f832757.tar.gz |
Bug#10224 - ANALYZE TABLE crashing with simultaneous CREATE ... SELECT statement.
Manual merge from 4.1.
mysql-test/r/create.result:
Auto merged
mysql-test/t/create.test:
Auto merged
sql/mysql_priv.h:
Auto merged
sql/sql_handler.cc:
Auto merged
sql/sql_insert.cc:
Auto merged
sql/sql_yacc.yy:
Auto merged
Diffstat (limited to 'mysql-test')
-rw-r--r-- | mysql-test/r/create.result | 18 | ||||
-rw-r--r-- | mysql-test/t/create.test | 30 |
2 files changed, 48 insertions, 0 deletions
diff --git a/mysql-test/r/create.result b/mysql-test/r/create.result index 34ccab9bcc5..ae09b8d730c 100644 --- a/mysql-test/r/create.result +++ b/mysql-test/r/create.result @@ -579,3 +579,21 @@ select * from t2; b 1 drop table t1,t2; +use test; +create table t1 (a int); +create table t1 select * from t1; +ERROR HY000: You can't specify target table 't1' for update in FROM clause +create table t2 union = (t1) select * from t1; +ERROR HY000: You can't specify target table 't1' for update in FROM clause +flush tables with read lock; +unlock tables; +drop table t1; +create table t1(column.name int); +ERROR 42000: Incorrect table name 'column' +create table t1(test.column.name int); +ERROR 42000: Incorrect table name 'column' +create table t1(xyz.t1.name int); +ERROR 42000: Incorrect database name 'xyz' +create table t1(t1.name int); +create table t2(test.t2.name int); +drop table t1,t2; diff --git a/mysql-test/t/create.test b/mysql-test/t/create.test index d4733e6dc7e..d9712a28788 100644 --- a/mysql-test/t/create.test +++ b/mysql-test/t/create.test @@ -471,3 +471,33 @@ insert into t2 values (); select * from t1; select * from t2; drop table t1,t2; + +# +# Bug#10224 - ANALYZE TABLE crashing with simultaneous +# CREATE ... SELECT statement. +# This tests two additional possible errors and a hang if +# an improper fix is present. +# +connection default; +use test; +create table t1 (a int); +--error 1093 +create table t1 select * from t1; +--error 1093 +create table t2 union = (t1) select * from t1; +flush tables with read lock; +unlock tables; +drop table t1; + +# +# Bug#10413: Invalid column name is not rejected +# +--error 1103 +create table t1(column.name int); +--error 1103 +create table t1(test.column.name int); +--error 1102 +create table t1(xyz.t1.name int); +create table t1(t1.name int); +create table t2(test.t2.name int); +drop table t1,t2; |