summaryrefslogtreecommitdiff
path: root/mysql-test/r/sp-dynamic.result
diff options
context:
space:
mode:
authorunknown <bell@sanja.is.com.ua>2005-11-23 01:11:19 +0200
committerunknown <bell@sanja.is.com.ua>2005-11-23 01:11:19 +0200
commit164ce4c5cd8b18c6fe8f376ae7475622ce1cdb09 (patch)
tree06d46b3b6c54431d67d676751b91395a50392628 /mysql-test/r/sp-dynamic.result
parenta94df68628e98ebd4ac564414fc631c7afa6c495 (diff)
downloadmariadb-git-164ce4c5cd8b18c6fe8f376ae7475622ce1cdb09.tar.gz
Recursion support made for SP (BUG#10100).
client/mysqltest.c: An expected error messages hiding from the log if disable_result_log is in force. mysql-test/r/sp-dynamic.result: The test expanded for case of allowed/disalowed recursion. mysql-test/r/sp-error.result: Error messages changed. Test of bug11394() made with allowed recursion. mysql-test/r/sp.result: Tests for recursion. mysql-test/r/trigger.result: Check that triggers are not affected by this patch. mysql-test/r/variables.result: Test of max_sp_recursion_depth variable. mysql-test/t/sp-dynamic.test: The test expanded for case of allowed/disalowed recursion. mysql-test/t/sp-error.test: Error messages changed. Test of bug11394() made with allowed recursion. mysql-test/t/sp.test: Tests for recursion. mysql-test/t/trigger.test: Check that triggers are not affected by this patch. mysql-test/t/variables.test: Test of max_sp_recursion_depth variable. sql/item_func.cc: sp_find_function() and sp_find_procedure() joined to sp_find_routine() function as it was mentioned in TODO. sql/mysqld.cc: max_sp_recursion_depth variable added. sql/set_var.cc: max_sp_recursion_depth variable added. sql/share/errmsg.txt: An error message changed. An error message added. sql/sp.cc: sp_find_function() and sp_find_procedure() joined to sp_find_routine() function as it was mentioned in TODO. Temory LEX is allocated on a stack, not on a heap. Recursion support added for stored procedures. sql/sp.h: sp_find_function() and sp_find_procedure() joined to sp_find_routine() function as it was mentioned in TODO. sql/sp_head.cc: Initialization of new sp_head fields to get correct list of instances contained one instance only. Stack requirement for SP instruction is increased. Stack free space is checked before mem root initialisation to avoid memory leak. Pointer to the free instance management added before and after SP execution. sql/sp_head.h: New sp_head variables added to support inst of instances of SP for recursion and pointer on ths first free to use instance. sql/sql_base.cc: open_table() consume a lot of stack space so we check free stack space before it. sql/sql_class.h: max_sp_recursion_depth variable added. sql/sql_parse.cc: sp_find_function() and sp_find_procedure() joined to sp_find_routine() function as it was mentioned in TODO.
Diffstat (limited to 'mysql-test/r/sp-dynamic.result')
-rw-r--r--mysql-test/r/sp-dynamic.result15
1 files changed, 12 insertions, 3 deletions
diff --git a/mysql-test/r/sp-dynamic.result b/mysql-test/r/sp-dynamic.result
index 8fe469431cc..cf07f540608 100644
--- a/mysql-test/r/sp-dynamic.result
+++ b/mysql-test/r/sp-dynamic.result
@@ -33,6 +33,8 @@ begin
execute stmt;
end|
prepare stmt from "call p1()"|
+set @SAVE_SP_RECURSION_LEVELS=@@max_sp_recursion_depth|
+set @@max_sp_recursion_depth=100|
execute stmt|
ERROR HY000: The prepared statement contains a stored routine call that refers to that same statement. It's not allowed to execute a prepared statement in such a recursive manner
execute stmt|
@@ -40,11 +42,18 @@ ERROR HY000: The prepared statement contains a stored routine call that refers t
execute stmt|
ERROR HY000: The prepared statement contains a stored routine call that refers to that same statement. It's not allowed to execute a prepared statement in such a recursive manner
call p1()|
-ERROR HY000: Recursive stored routines are not allowed.
+ERROR HY000: The prepared statement contains a stored routine call that refers to that same statement. It's not allowed to execute a prepared statement in such a recursive manner
+call p1()|
+ERROR HY000: The prepared statement contains a stored routine call that refers to that same statement. It's not allowed to execute a prepared statement in such a recursive manner
+call p1()|
+ERROR HY000: The prepared statement contains a stored routine call that refers to that same statement. It's not allowed to execute a prepared statement in such a recursive manner
+set @@max_sp_recursion_depth=@SAVE_SP_RECURSION_LEVELS|
+call p1()|
+ERROR HY000: Recursive limit 0 (as set by the max_sp_recursion_depth variable) was exceeded for routine p1
call p1()|
-ERROR HY000: Recursive stored routines are not allowed.
+ERROR HY000: Recursive limit 0 (as set by the max_sp_recursion_depth variable) was exceeded for routine p1
call p1()|
-ERROR HY000: Recursive stored routines are not allowed.
+ERROR HY000: Recursive limit 0 (as set by the max_sp_recursion_depth variable) was exceeded for routine p1
drop procedure p1|
create procedure p1()
begin