create trigger

    0

    0

    lucycodes42

    SQL public snippets

    The trigger created in the code example will execute once for each row in the table_name table. The trigger will execute the code block that begins with the &[USER_INPUT:5: -- Use NEW and OLD constants for access to row] keyword. The two constants used in the code block are NEW and OLD. NEW represents the current row number and OLD represents the row number for the row that was inserted before the current row.

    Shortcut: s_trig

    CREATE TRIGGER `trigger_name` AFTER INSERT ON `table_name` FOR EACH ROW
    BEGIN
        constants
    END;
    Codiga Logo
    Codiga Hub
    • Rulesets
    • Playground
    • Snippets
    • Cookbooks
    soc-2 icon

    We are SOC-2 Compliance Certified

    G2 high performer medal

    Codiga – All rights reserved 2022.