DROP TRIGGER

Removes a trigger from a table.

SYNTAX

trigger_name Name of the trigger you want to remove.
table_name Name of the table you want to remove the trigger from.

DESCRIPTION

The DROP TRIGGER command removes an existing trigger from a database. To execute the DROP TRIGGER command to drop a trigger from a table you must be the table owner, or have DBA or SYSADM security privileges.

A trigger is a database server mechanism that automatically executes predefined commands in response to specific events. This allows a database to perform complex or unconventional operations that might not be possible using standard SQL commands. Since triggers are under the control of the database server, they can ensure data is handled consistently regardless of the source. Once you create a trigger on a table, its operation is transparent to users of the database; DBMaker will fire the trigger every time a user or application program generates a trigger event.

If you drop a table or a column that is referenced by a trigger, alter a table and modify the column definition, or alter a table and add a column using the BEFORE and AFTER keywords, the trigger becomes invalid and cannot be used again. Altering a table and adding a column without using the BEFORE and AFTER keywords will have no impact on a trigger. You can drop an invalid trigger to remove it from the database. Any triggers you create on a table are dropped automatically if you drop the table.

EXAMPLE

The following example drops the trigger named Trig1 from the Employees table.

DROP TRIGGER Trig1 FROM Employees

RELATED COMMANDS

< DROP TEXT INDEX | Contents | DROP VIEW >

Copyright 2002 SYSCOM Computer Engineering Co. All rights reserved.