diff options
author | kaa@polly.local <> | 2006-11-20 17:35:23 +0300 |
---|---|---|
committer | kaa@polly.local <> | 2006-11-20 17:35:23 +0300 |
commit | 346033a5dab56766dbe2a5bb060f4235844d6c16 (patch) | |
tree | c0d411207a9f398911d37b202d2c4fcd26ecf631 /mysql-test/t/read_only.test | |
parent | 8471897fbc01520bfdf93a7105019e17cdbca89e (diff) | |
download | mariadb-git-346033a5dab56766dbe2a5bb060f4235844d6c16.tar.gz |
Fix for bug #22077 "DROP TEMPORARY TABLE fails with wrong error if read_only is set"
Do not issue a 'read-only' error in case of DROP TEMPORARY TABLE on a non-existing temporary table.
Instead produce the correct "Unknown table" error or warning (in cases when the IF EXISTS clause was specified).
To a documentor: the part of the manual describing the 'read_only' system variable should be clarified to state the following:
"When the read_only variable is set to ON, all operations which create/update/drop tables are rejected with the exceptions for:
1. Any operation performed by the replication thread on a slave server
2. Any operation performed by a user that have the SUPER privilege
3. Any operation that creates/updates/drops only temporary tables"
Diffstat (limited to 'mysql-test/t/read_only.test')
-rw-r--r-- | mysql-test/t/read_only.test | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/mysql-test/t/read_only.test b/mysql-test/t/read_only.test index 175a5bba6fa..8e14b310f4c 100644 --- a/mysql-test/t/read_only.test +++ b/mysql-test/t/read_only.test @@ -101,6 +101,18 @@ drop table t1; --error 1290 insert into t1 values(1); +# +# BUG #22077 "DROP TEMPORARY TABLE fails with wrong error if read_only is set" +# +# check if DROP TEMPORARY on a non-existing temporary table returns the right +# error + +--error ER_BAD_TABLE_ERROR +drop temporary table ttt; + +# check if DROP TEMPORARY TABLE IF EXISTS produces a warning with read_only set +drop temporary table if exists ttt; + connection default; drop table t1,t2; drop user test@localhost; |