If you don't want to create a custom metric and alert from scratch, we've provided a website, SQL Monitor Metrics, containing a range of metrics that you can install automatically. Automatic installation is only available in SQL Monitor 3.2 and later.
To create a custom metric:
Go to the Configuration tab. Under Alerts and metrics, select Custom metrics:
Click the Create custom metric button:
The first page of a simple, three-step wizard is displayed. The steps are:
Step 1. Define metric - includes sections for defining the metric, and entering and testing the T-SQL query on which the metric is based.
Step 2. Add an alert - optionally base an alert on the metric by completing sections similar to those displayed on the Alert settings page (Configuration > Alert settings).