t restrict */
/* ERWIN_RELATION: CHECKSUM = "00000000", PARENT_OWNER = "", PARENT_TABLE = "Orderer" _OWNER = "", CHILD_TABLE = "Ord" C_VERB_PHRASE = "" ;, C2P_VERB_PHRASE = "", _CONSTRAINT = "R_5", FK_COLUMNS = "N_S_ord" */count (*) INTO NUMROWSOrderer
/*% JoinFKPK (:% New, Orderer, "=", "AND") */
: new.N_S_ord = Orderer.N_S_ord; (
/*% NotnullFK (:% New, "IS NOT NULL AND") */= 0
) _application_error (
,
'Cannot insert Ord because Orderer does not exist.'
); IF;
- ERwin Builtin Trigger;
/ TRIGGER tD_Ord AFTER DELETE ON Ord for each row
- ERwin Builtin Trigger
- DELETE trigger on OrdNUMROWS INTEGER;
/* ERwin Builtin Trigger */
/* Ord Ord_del on parent delete restrict */
/* ERWIN_RELATION: CHECKSUM = "00010cd1", PARENT_OWNER = "", PARENT_TABLE = "Ord" _OWNER = "", CHILD_TABLE = "Ord_del" C_VERB_PHRASE = "" ;, C2P_VERB_PHRASE = "", _CONSTRAINT = "R_7", FK_COLUMNS = "ID_ordering" "Summ" "N_S_ord" "Delivery" */count (*) INTO NUMROWSOrd_del
/* % JoinFKPK (Ord_del,:% Old, "=", "AND") */_del.ID_ordering =: old.ID_ordering AND_del.Summ =: old.Summ AND_del.N_S_ord =: old.N_S_ord AND_del.Delivery =: old.Delivery; (NUMROWS> 0) _application_error (
,
'Cannot delete Ord because Ord_del exists.'
); IF;
- ERwin Builtin Trigger;
/ TRIGGER tU_Ord AFTER UPDATE ON Ord for each row
- ERwin Builtin Trigger
- UPDATE trigger on OrdNUMROWS INTEGER;
/* ERwin Builtin Trigger */
/* Ord Ord_del on parent update restrict */
/* ERWIN_RELATION: CHECKSUM = "0003 0f78 ", PARENT_OWNER =" ", PARENT_TABLE =" Ord "_OWNER =" ", CHILD_TABLE =" Ord_del "C_VERB_PHRASE =" ", C2P_VERB_PHRASE =" ", _CONSTRAINT =" R_7 ", FK_COLUMNS = "ID_ordering" "Summ" "N_S_ord" "Delivery" */
/*% JoinPKPK (:% Old,:% New, "<>", "OR") */
: old.ID_ordering <>: new.ID_orderingcount (*) INTO NUMROWSOrd_del
/* % JoinFKPK (Ord_del,:% Old, "=", "AND") */_del.ID_ordering =: old.ID_ordering...