| title | sp_delete_notification (Transact-SQL) | Microsoft Docs | ||
|---|---|---|---|
| ms.custom | |||
| ms.date | 03/14/2017 | ||
| ms.prod | sql-non-specified | ||
| ms.reviewer | |||
| ms.suite | |||
| ms.technology |
|
||
| ms.tgt_pltfrm | |||
| ms.topic | language-reference | ||
| f1_keywords |
|
||
| dev_langs |
|
||
| helpviewer_keywords |
|
||
| ms.assetid | b55d3898-596d-47a5-a4f0-d65dc736223b | ||
| caps.latest.revision | 21 | ||
| author | JennieHubbard | ||
| ms.author | jhubbard | ||
| manager | jhubbard |
[!INCLUDEtsql-appliesto-ss2008-xxxx-xxxx-xxx_md]
Removes a [!INCLUDEssNoVersion] Agent notification definition for a specific alert and operator.
Transact-SQL Syntax Conventions
sp_delete_notification
[ @alert_name = ] 'alert' ,
[ @operator_name = ] 'operator'
[ @alert_name= ] 'alert'
The name of the alert. alert is sysname, with no default.
[ @operator_name= ] 'operator'
The name of the operator. operator is sysname, with no default.
0 (success) or 1 (failure)
None
Removing a notification removes only the notification; the alert and the operator are left intact.
To run this stored procedure, users must be granted the sysadmin fixed server role.
The following example removes the notification sent to operator François Ajenstat when alert Test Alert occurs.
USE msdb ;
GO
EXEC dbo.sp_delete_notification
@alert_name = 'Test Alert',
@operator_name = 'François Ajenstat' ;
GO
sp_add_alert (Transact-SQL)
sp_add_notification (Transact-SQL)
sp_add_operator (Transact-SQL)
sp_delete_alert (Transact-SQL)
sp_help_alert (Transact-SQL)
sp_help_notification (Transact-SQL)
sp_help_operator (Transact-SQL)
sp_update_notification (Transact-SQL)
System Stored Procedures (Transact-SQL)