What are the advantages of using triggers over stored procedures in certain scenarios?

  • All of the above
  • Enhanced performance
  • Improved data integrity
  • Reduced application complexity
Triggers in DB2 offer improved data integrity by enforcing constraints and business rules directly at the database level. This ensures that data remains consistent and valid, regardless of how it is accessed or modified. While stored procedures can also enhance data integrity, triggers provide an additional layer of protection by automatically executing when specific events occur, without requiring explicit invocation by applications. 
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *