mirror of
https://github.com/MariaDB/server.git
synced 2025-12-24 11:21:21 +03:00
Fixed BUG#336: Subselects with tables does not work as values for local SP variables
and BUG#1654: Stored Procedure Crash if contains subquery and set function Disallowed subselects in RETURN (for FUNCTIONs) and SET of local variables. The latter should work, but turned out to be difficult to fix, so we just disallow it for the time being.
This commit is contained in:
@@ -361,6 +361,23 @@ drop procedure bug1965|
|
||||
--error 1309
|
||||
select 1 into a|
|
||||
|
||||
#
|
||||
# BUG#336
|
||||
#
|
||||
--error 1317
|
||||
create procedure bug336(id char(16))
|
||||
begin
|
||||
declare x int;
|
||||
set x = (select sum(t.data) from test.t2 t);
|
||||
end|
|
||||
|
||||
#
|
||||
# BUG#1654
|
||||
#
|
||||
--error 1296
|
||||
create function bug1654()
|
||||
returns int
|
||||
return (select sum(t.data) from test.t2 t)|
|
||||
|
||||
drop table t1|
|
||||
|
||||
|
||||
Reference in New Issue
Block a user