How can we destroy a trigger?

We can destroy a trigger in two ways −

Dropping a trigger explicitly

With the help of the DROP statement, we can destroy a trigger explicitly. It can be understood with the help of the following example −

mysql> DROP Trigger before_inser_studentage1;
Query OK, 0 rows affected (0.05 sec)

Dropping a trigger implicitly

A trigger will be destroyed implicitly if the table with which it is associated is destroyed or if the database which it is associated is destroyed.

Monica Mona
Monica Mona

Student of life, and a lifelong learner