Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
9ff59261
Commit
9ff59261
authored
Nov 24, 2006
by
kaa@polly.local
Browse files
Options
Browse Files
Download
Plain Diff
Merge polly.local:/tmp/maint/bug22077/my50-bug22077
into polly.local:/tmp/maint/bug22077/my51-bug22077
parents
67ca3dde
346033a5
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
4 deletions
+22
-4
mysql-test/r/read_only.result
mysql-test/r/read_only.result
+5
-0
mysql-test/t/read_only.test
mysql-test/t/read_only.test
+12
-0
sql/sql_parse.cc
sql/sql_parse.cc
+5
-4
No files found.
mysql-test/r/read_only.result
View file @
9ff59261
...
@@ -39,6 +39,11 @@ delete t1 from t1,t3 where t1.a=t3.a;
...
@@ -39,6 +39,11 @@ delete t1 from t1,t3 where t1.a=t3.a;
drop table t1;
drop table t1;
insert into t1 values(1);
insert into t1 values(1);
ERROR HY000: The MySQL server is running with the --read-only option so it cannot execute this statement
ERROR HY000: The MySQL server is running with the --read-only option so it cannot execute this statement
drop temporary table ttt;
ERROR 42S02: Unknown table 'ttt'
drop temporary table if exists ttt;
Warnings:
Note 1051 Unknown table 'ttt'
drop table t1,t2;
drop table t1,t2;
drop user test@localhost;
drop user test@localhost;
set global read_only=0;
set global read_only=0;
mysql-test/t/read_only.test
View file @
9ff59261
...
@@ -101,6 +101,18 @@ drop table t1;
...
@@ -101,6 +101,18 @@ drop table t1;
--
error
1290
--
error
1290
insert
into
t1
values
(
1
);
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
;
connection
default
;
drop
table
t1
,
t2
;
drop
table
t1
,
t2
;
drop
user
test
@
localhost
;
drop
user
test
@
localhost
;
...
...
sql/sql_parse.cc
View file @
9ff59261
...
@@ -2566,6 +2566,7 @@ mysql_execute_command(THD *thd)
...
@@ -2566,6 +2566,7 @@ mysql_execute_command(THD *thd)
(
sql_command_flags
[
lex
->
sql_command
]
&
CF_CHANGES_DATA
)
&&
(
sql_command_flags
[
lex
->
sql_command
]
&
CF_CHANGES_DATA
)
&&
!
((
lex
->
sql_command
==
SQLCOM_CREATE_TABLE
)
&&
!
((
lex
->
sql_command
==
SQLCOM_CREATE_TABLE
)
&&
(
lex
->
create_info
.
options
&
HA_LEX_CREATE_TMP_TABLE
))
&&
(
lex
->
create_info
.
options
&
HA_LEX_CREATE_TMP_TABLE
))
&&
!
((
lex
->
sql_command
==
SQLCOM_DROP_TABLE
)
&&
lex
->
drop_temporary
)
&&
((
lex
->
sql_command
!=
SQLCOM_UPDATE_MULTI
)
&&
((
lex
->
sql_command
!=
SQLCOM_UPDATE_MULTI
)
&&
some_non_temp_table_to_be_updated
(
thd
,
all_tables
)))
some_non_temp_table_to_be_updated
(
thd
,
all_tables
)))
{
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment