mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Fixed trigger.test after fixing bug #11554 "Server crashes on statement
indirectly using non-cached function". mysql-test/r/trigger.result: Fixed test case after fixing bug #11554 "Server crashes on statement indirectly using non-cached function". mysql-test/t/trigger.test: Fixed test case after fixing bug #11554 "Server crashes on statement indirectly using non-cached function".
This commit is contained in:
@ -232,9 +232,6 @@ if new.id > f1() then
|
|||||||
set new.id:= f1();
|
set new.id:= f1();
|
||||||
end if;
|
end if;
|
||||||
end|
|
end|
|
||||||
select f1();
|
|
||||||
f1()
|
|
||||||
10
|
|
||||||
insert into t1 values (1, "first");
|
insert into t1 values (1, "first");
|
||||||
insert into t1 values (f1(), "max");
|
insert into t1 values (f1(), "max");
|
||||||
select * from t1;
|
select * from t1;
|
||||||
@ -573,3 +570,12 @@ i k ts
|
|||||||
1 1 0000-00-00 00:00:00
|
1 1 0000-00-00 00:00:00
|
||||||
2 2 0000-00-00 00:00:00
|
2 2 0000-00-00 00:00:00
|
||||||
drop table t1, t2;
|
drop table t1, t2;
|
||||||
|
drop function if exists bug5893;
|
||||||
|
create table t1 (col1 int, col2 int);
|
||||||
|
insert into t1 values (1, 2);
|
||||||
|
create function bug5893 () returns int return 5;
|
||||||
|
create trigger t1_bu before update on t1 for each row set new.col1= bug5893();
|
||||||
|
drop function bug5893;
|
||||||
|
update t1 set col2 = 4;
|
||||||
|
ERROR 42000: FUNCTION test.bug5893 does not exist
|
||||||
|
drop table t1;
|
||||||
|
@ -244,8 +244,6 @@ begin
|
|||||||
end if;
|
end if;
|
||||||
end|
|
end|
|
||||||
delimiter ;|
|
delimiter ;|
|
||||||
# Remove this once bug #11554 will be fixed.
|
|
||||||
select f1();
|
|
||||||
insert into t1 values (1, "first");
|
insert into t1 values (1, "first");
|
||||||
insert into t1 values (f1(), "max");
|
insert into t1 values (f1(), "max");
|
||||||
select * from t1;
|
select * from t1;
|
||||||
@ -578,15 +576,14 @@ drop table t1, t2;
|
|||||||
|
|
||||||
# Test for bug #5893 "Triggers with dropped functions cause crashes"
|
# Test for bug #5893 "Triggers with dropped functions cause crashes"
|
||||||
# Appropriate error should be reported instead of crash.
|
# Appropriate error should be reported instead of crash.
|
||||||
# Had to disable this test until bug #11554 will be fixed.
|
--disable_warnings
|
||||||
#--disable_warnings
|
drop function if exists bug5893;
|
||||||
#drop function if exists bug5893;
|
--enable_warnings
|
||||||
#--enable_warnings
|
create table t1 (col1 int, col2 int);
|
||||||
#create table t1 (col1 int, col2 int);
|
insert into t1 values (1, 2);
|
||||||
#insert into t1 values (1, 2);
|
create function bug5893 () returns int return 5;
|
||||||
#create function bug5893 () returns int return 5;
|
create trigger t1_bu before update on t1 for each row set new.col1= bug5893();
|
||||||
#create trigger t1_bu before update on t1 for each row set new.col1= bug5893();
|
drop function bug5893;
|
||||||
#drop function bug5893;
|
--error 1305
|
||||||
#--error 1305
|
update t1 set col2 = 4;
|
||||||
#update t1 set col2 = 4;
|
drop table t1;
|
||||||
#drop table t1;
|
|
||||||
|
Reference in New Issue
Block a user