Assert verifies that trigger exists. Fail when trigger with a given name has not been found in the database.

Note:
- Supported in Oracle and SQL Server framework versions.
- Netezza does not support triggers officially, however appliance does have _v_trigger system view that might allow users in the future to use this functionality (at list for system objects)

Arguments

  • v_TriggerName – trigger name, Variable Character(255) in Oracle and Netezza, SYSNAME in SQL Server
  • v_UserMessage – message to report when assertion fails, Variable Character(255) in Oracle and Netezza, NVARCHAR(MAX) in SQL Server

 

Examples

Netezza

CALL DBTD_ASSERT_TRIGGER_EXISTS ('tr_bfr_ins_prod_tbl', 'cannot find trigger');

Oracle

DBTD_ASSERT_TRIGGER_EXISTS ('tr_bfr_ins_prod_tbl', 'cannot find trigger');

SQL Server 

EXEC DBTD_ASSERT_TRIGGER_EXISTS 'tr_bfr_ins_prod_tbl', 'cannot find trigger';

 
See Also