📜  创建d'un trigger sql代码示例

📅  最后修改于: 2022-03-11 15:04:51.036000             🧑  作者: Mango

代码示例1
CREATE OR REPLACE TRIGGER trigg_example
 BEFORE INSERT OR UPDATE ON table_example
 FOR EACH ROW
 WHEN (new.no_line > 0)
 DECLARE
     evol_exemple number;
 BEGIN
     evol_exemple := :new.exemple  - :old.exemple;
     DBMS_OUTPUT.PUT_LINE('  evolution : ' || evol_exemple);
 END;