sp_delete_alert (T-SQL)

Removes an alert.

Syntax

sp_delete_alert [@name =] 'name'

Arguments
[@name =] 'name'
Is the name of the alert. name is sysname, with no default.
Return Code Values

0 (success) or 1 (failure)

Result Sets

None

Remarks

Removing an alert also removes any notifications associated with the alert.

sp_delete_alert must be executed in the msdb database.

Permissions

Only members of the sysadmin fixed server role or the db_owner fixed database role can execute sp_delete_alert.

Examples

This example removes an alert named Test Alert.

sp_delete 'Test Alert'

  

See Also
sp_add_alert System Stored Procedures
sp_help_alert  

  


(c) 1988-98 Microsoft Corporation. All Rights Reserved.