This sample works only with SQL Server 2005 and SQL Server 2008. It will not work with any version of SQL Server earlier than SQL Server 2005.
The purpose of the Alerts sample is to demonstrate the alert capabilities of SQL Server. For more information, see "Defining Alerts" in SQL Server Books Online.
| Important: |
| Samples are provided for educational purposes only. They are not intended to be used in a production environment and have not been tested in a production environment. Microsoft does not provide technical support for these samples. Sample applications and assemblies should not be connected to or used with your production SQL Server database or your report server without the permission of the system administrator. |
This sample script file creates SQL Server Agent alerts in SQL Server.
After the execution of this script you will find new alerts added to the alerts collection. You can examine them in SQL Server Management Studio or by calling sp_help_alert stored procedure.
Before you run this sample, perform the following tasks:
Running the Sample
The following procedure shows how to run the Alerts sample.
Running the Alerts Sample
- From Management Studio, open the agentsamplealerts.sql script. The default installation directory is C:\Program Files\Microsoft SQL Server\100\Samples\Engine\Administration\Alerts\Scripts.
- Click Execute. © 2008 Microsoft Corporation. All rights reserved.