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
9cf77e40
Commit
9cf77e40
authored
Sep 14, 2005
by
pem@mysql.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Post-review fix for BUG#12712: SET AUTOCOMMIT should fail within SP/functions/triggers
parent
d825ed1a
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
10 deletions
+12
-10
mysql-test/r/sp.result
mysql-test/r/sp.result
+1
-0
mysql-test/t/sp.test
mysql-test/t/sp.test
+1
-0
sql/sp_head.h
sql/sp_head.h
+2
-1
sql/sql_yacc.yy
sql/sql_yacc.yy
+8
-9
No files found.
mysql-test/r/sp.result
View file @
9cf77e40
...
...
@@ -3323,6 +3323,7 @@ drop function bug12379|
drop procedure bug12379_1|
drop procedure bug12379_2|
drop procedure bug12379_3|
drop table t3|
drop procedure if exists bug13124|
create procedure bug13124()
begin
...
...
mysql-test/t/sp.test
View file @
9cf77e40
...
...
@@ -4161,6 +4161,7 @@ drop function bug12379|
drop
procedure
bug12379_1
|
drop
procedure
bug12379_2
|
drop
procedure
bug12379_3
|
drop
table
t3
|
#
# Bug #13124 Stored Procedure using SELECT INTO crashes server
...
...
sql/sp_head.h
View file @
9cf77e40
...
...
@@ -285,7 +285,8 @@ public:
my_error
(
ER_SP_NO_RETSET
,
MYF
(
0
),
where
);
else
if
(
m_flags
&
HAS_SET_AUTOCOMMIT_STMT
)
my_error
(
ER_SP_CANT_SET_AUTOCOMMIT
,
MYF
(
0
));
return
test
(
m_flags
&
(
CONTAINS_DYNAMIC_SQL
|
MULTI_RESULTS
));
return
test
(
m_flags
&
(
CONTAINS_DYNAMIC_SQL
|
MULTI_RESULTS
|
HAS_SET_AUTOCOMMIT_STMT
));
}
private:
...
...
sql/sql_yacc.yy
View file @
9cf77e40
...
...
@@ -8005,15 +8005,14 @@ internal_variable_name:
if (tmp == &sys_time_zone &&
lex->add_time_zone_tables_to_query_tables(YYTHD))
YYABORT;
else
if (spc && tmp == &sys_autocommit)
{
/*
We don't allow setting AUTOCOMMIT from a stored function
or trigger.
*/
lex->sphead->m_flags|= sp_head::HAS_SET_AUTOCOMMIT_STMT;
}
else if (spc && tmp == &sys_autocommit)
{
/*
We don't allow setting AUTOCOMMIT from a stored function
or trigger.
*/
lex->sphead->m_flags|= sp_head::HAS_SET_AUTOCOMMIT_STMT;
}
}
else
{
...
...
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