summaryrefslogtreecommitdiff
path: root/sql/sp_head.cc
diff options
context:
space:
mode:
authormalff/marcsql@weblab.(none) <>2006-10-19 11:39:51 -0700
committermalff/marcsql@weblab.(none) <>2006-10-19 11:39:51 -0700
commitea0998cacafce4e5efca6de8ccfd135b10adc5b3 (patch)
tree997ff98a25d591733b1ee8e0a441ad58f17eaaaa /sql/sp_head.cc
parentdea0028cd951fc6fb2b898842e8f304bcfc6c532 (diff)
downloadmariadb-git-ea0998cacafce4e5efca6de8ccfd135b10adc5b3.tar.gz
Bug#20028 (Function with select return no data)
This patch reverts a change introduced by Bug 6951, which incorrectly set thd->abort_on_warning for stored procedures. As per internal discussions about the SQL_MODE=TRADITIONAL, the correct behavior is to *not* abort on warnings even inside an INSERT/UPDATE trigger. Tests for Stored Procedures, Stored Functions, Triggers involving SQL_MODE have been included or revised, to reflect the intended behavior. (reposting approved patch, to work around source control issues, no review needed)
Diffstat (limited to 'sql/sp_head.cc')
-rw-r--r--sql/sp_head.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/sql/sp_head.cc b/sql/sp_head.cc
index 9761de625be..a06bfe28a6f 100644
--- a/sql/sp_head.cc
+++ b/sql/sp_head.cc
@@ -991,8 +991,7 @@ sp_head::execute(THD *thd)
save_sql_mode= thd->variables.sql_mode;
thd->variables.sql_mode= m_sql_mode;
save_abort_on_warning= thd->abort_on_warning;
- thd->abort_on_warning=
- (m_sql_mode & (MODE_STRICT_TRANS_TABLES | MODE_STRICT_ALL_TABLES));
+ thd->abort_on_warning= 0;
/*
It is also more efficient to save/restore current thd->lex once when