Use the object-list format to change the mode for one or more constraint, index, or trigger.
Object-List Format: .-,----------. V | (1) |--+-CONSTRAINTS----constraint-+--| Modes for Constraints and Unique Indexes |------+--| | .-,-----. | | V | (1) | +-INDEXES----index-+--+-| Modes for Constraints and Unique Indexes |------+------+ | | (2) | | | '-| Modes for Triggers and Duplicate Indexes |------' | | .-,-------. | | V | | '-TRIGGERS----trigger-+--+---------------------------------------------------+---' | (2) | '-| Modes for Triggers and Duplicate Indexes |------'
Element | Description | Restrictions | Syntax |
---|---|---|---|
constraint | Name of a constraint whose mode is to be set | Must be a local constraint, and all constraints in the list must be defined on the same table | Database Object Name, p. Database Object Name |
index | Name of an index whose mode is to be set | Must be a local index, and all indexes in the list must be defined on the same table | Database Object Name, p. Database Object Name |
trigger | Name of a trigger whose mode is to be set | Must be a local trigger, and all triggers in the list must be defined on the same table or view | Database Object Name, p. Database Object Name |
For example, to change the mode of the unique index unq_ssn on the cust_subset table to filtering, enter the following statement:
SET INDEXES unq_ssn FILTERING
You can also use the object-list format to change the mode for a list of constraints, indexes, or triggers that are defined on the same table. Assume that four triggers are defined on the cust_subset table: insert_trig, update_trig, delete_trig, and execute_trig. Also assume that all four triggers are enabled. To disable all triggers except execute_trig, enter this statement:
SET TRIGGERS insert_trig, update_trig, delete_trig DISABLED
If my_trig is a disabled INSTEAD OF trigger on a view, the following statement enables that trigger:
SET TRIGGERS my_trig ENABLEDEnterprise Edition Home | Express Edition Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]