1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

A fix for

Bug#12093 "SP not found on second PS execution if another thread 
drops other SP in between" and
Bug#21294 "executing a prepared statement that executes a stored 
function which was recreat"

Stored functions are resolved at prepared statement prepare only.
If someone flushes the stored functions cache between prepare and
execute, execution fails.

The fix is to detect the situation of the cache flush and automatically
reprepare the prepared statement after it.
This commit is contained in:
Konstantin Osipov
2008-07-03 23:41:22 +04:00
parent 0da3a20150
commit 29defdb5f0
9 changed files with 112 additions and 64 deletions

View File

@ -796,7 +796,7 @@ bug11834_2()
10
drop function bug11834_1;
execute stmt;
ERROR 42000: FUNCTION test.bug11834_2 does not exist
ERROR 42000: FUNCTION test.bug11834_1 does not exist
deallocate prepare stmt;
drop function bug11834_2;
DROP FUNCTION IF EXISTS bug12953|
@ -1045,7 +1045,8 @@ select bug12329();
bug12329()
101
execute stmt1;
ERROR 42S02: Table 'test.t2' doesn't exist
bug12329()
101
deallocate prepare stmt1;
drop function bug12329;
drop table t1, t2;