触发器:
create or replace trigger MyTrig1
before update on cm_customer
for each row
declare
-- local variables here
begin
RAISE_APPLICATION_ERROR(-20500,
'You may insert' ||
' into EMPLOYEES table only during ' ||
' business hours.');
dbms_output.put_line('update...');
end MyTrig1;
本文介绍了一个Oracle数据库触发器的实现案例,该触发器在特定条件下阻止对cm_customer表进行更新操作。通过使用RAISE_APPLICATION_ERROR过程,在非工作时间尝试更新表时引发错误。
211

被折叠的 条评论
为什么被折叠?



