create or replace trigger del_dept
before delete on dept
begin
if deleting then
raise_application_error(-20020,'禁止删除表dept中的记录');
end if;
end;
这样做的效果不是很好.引发应用程序错误,会导致整个引用程序终止.谁能给出个好点的方法,
禁止删除dept表中的记录,我希望的目的是,删除可以执行但是表中的记录不会受影响.
before delete on dept
begin
if deleting then
raise_application_error(-20020,'禁止删除表dept中的记录');
end if;
end;
这样做的效果不是很好.引发应用程序错误,会导致整个引用程序终止.谁能给出个好点的方法,
禁止删除dept表中的记录,我希望的目的是,删除可以执行但是表中的记录不会受影响.
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货