drop trigger

Removes a trigger.

Syntax

drop trigger [owner.]trigger_name 
	[, [owner.]trigger_name] ...

Parameters

Examples

Usage

  • drop trigger drops a trigger in the current database.

  • You need not explicitly drop a trigger from a table to create a new trigger for the same operation (insert, update, or delete). In a table or column, each new trigger for the same operation overwrites the previous one.

  • When a table is dropped, the SAP ASE server automatically drops any triggers associated with it.

  • You can use drop trigger to remove or replace an existing trigger, or multiple triggers. The drop trigger command drops a single trigger. If you have multiple triggers on a table, you can drop them individually.

See also sp_depends, sp_help, sp_helptext in Reference Manual: Procedures.

Standards

ANSI SQL – Compliance level: Transact-SQL extension.

Permissions

The permission checks for drop trigger differ based on your granular permissions settings.

SettingDescription
Enabled

With granular permissions enabled, you must be the trigger owner or a user with drop any trigger privilege.

Disabled

With granular permissions disabled, you must be the trigger owner or a user with sa_role.

Auditing

Values in event and extrainfo columns of sysaudits are:

InformationValues
Event

29

Audit option

drop

Command or access audited

drop trigger

Information in extrainfo
  • Roles – current active roles

  • Keywords or options – NULL

  • Previous value – NULL

  • Current value – NULL

  • Other information – NULL

  • Proxy information – original login name, if set proxy is in effect

Related reference
create trigger