Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.
Drops a user-defined trace event.
DROP TRACE EVENT [ IF EXISTS ] trace-event-name
This statement only drops user-defined trace events. If you do not want an error returned when the DROP TRACE EVENT statement attempts to remove a trace event that does not exist, use the IF EXISTS clause. If one ore more event tracing sessions reference the trace event, then the trace event cannot be dropped until all the referencing trace sessions are dropped.
You must have the MANAGE ANY TRACE SESSION system privilege.
Not in the standard.
Drop the trace event named my_event:
DROP TRACE EVENT my_event;