MySQL Triggers


  1. What is def in the following statement?
    DECLARE pqr HANDLER FOR def mno;











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: D

    The ‘DECLARE HANDLER’ statement is used to declare a handler. When a condition whose value matches def, MySQL will execute ghi and either continue or exit the current code block.


  1. What is ghi in the following statement?
    CREATE TRIGGER pqr(...) (...) ON def FOR EACH ROW mno;











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: B

    In MySQL, the trigger creation construct is the ‘CREATE TRIGGER’ construct. It specifies components like the trigger name, the type of statement for which it is activated, and the table name and statement.



  1. What is def in the following statement?
    CREATE TRIGGER pqr(...) (...) ON def FOR EACH ROW mno;











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: A

    The trigger creation construct in MySQL is the ‘CREATE TRIGGER’ construct. It specifies components like the trigger name, the type of statement for which it is activated, and the table name and statement.


  1. What is abc in the following statement?
    CREATE TRIGGER pqr(...) (...) ON def FOR EACH ROW mno;











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: D

    In MySQL, the trigger creation construct is the ‘CREATE TRIGGER’ construct. It specifies the trigger name, the type of statement for which it is activated, and the table name and statement.



  1. The TRIGGER privilege is used for the table to be able to create and drop triggers for it.











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: B

    In MySQL, because a trigger is associated with a table, the TRIGGER privilege is a must for that table to be able to create and drop triggers for it. The SUPER privilege was used pre 5.1.6.