Details
-
Technical task
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
Description
A trigger in Oracle is generally combined into one for all events (INSERT, UPDATE & DELETE) This is not supported by MariaDB
Here is an example code for a typical trigger in Oracle:
CREATE TRIGGER trg_name AFTER INSERT OR UPDATE OR DELETE ON Table_Name |
FOR EACH ROW |
BEGIN
|
IF INSERTING THEN |
Do Something here...
|
END IF; |
|
IF UPDATING THEN |
Do Something here...
|
END IF; |
|
IF DELETING THEN |
Do Something here...
|
END IF; |
END; |
Oracle Doc: https://docs.oracle.com/cd/A57673_01/DOC/server/doc/SCN73/ch15.htm