我正在尝试使用别名创建触发器,但是我收到错误:
delimiter |
create trigger death before insert on retiree_hist RH
for each row
begin
delete from myjobdata JD
where JD.emplid = RH.emplid;
end;|
delimiter ;
我了解到别名不能使用触发器。有没有办法解决?
答案 0 :(得分:1)
delimiter |
create trigger death before insert on retiree_hist
for each row
begin
delete from myjobdata
where myjobdata.emplid = NEW.emplid;
end
|
delimiter ;