Help Center/ Relational Database Service_RDS for SQL Server/ User Guide/ Usage of Stored Procedures/ Removing SQL Server Agent Notification Definitions for Specific Alerts and Operators
Updated on 2025-06-30 GMT+08:00

Removing SQL Server Agent Notification Definitions for Specific Alerts and Operators

Scenarios

You can use a stored procedure to remove a SQL Server Agent notification definition for a specific alert and operator.

Prerequisites

An RDS for SQL Server DB instance has been connected. You can connect to the DB instance through a SQL Server client. For details, see Connecting to a DB Instance Through a Public Network.

Procedure

Run the following commands to remove the RDS for SQL Server Agent notification definition for a specific alert and operator:

EXEC [msdb].[dbo].[rds_delete_notification]

@alert_name = 'alert',

@operator_name ='operator';

Table 1 Parameter description

Parameter

Description

'alert'

The name of the alert. This parameter is of sysname data type, with no default value.

'operator'

The name of the operator. This parameter is of sysname data type, with no default value.

After the command is executed, the system displays the following information.

Commands completed successfully.

Example

EXEC [msdb].[dbo].[rds_delete_notification]

@alert_name = 'alert',

@operator_name = N'TestOperator';

The command output is as follows.