EnumJobNotifications Method
Questa funzionalità verrà rimossa in una delle prossime versioni di Microsoft SQL Server. Evitare di utilizzare questa funzionalità in un nuovo progetto di sviluppo e prevedere interventi di modifica nelle applicazioni in cui è attualmente implementata.
The EnumJobNotifications method returns a QueryResults object that enumerates notifications made by Microsoft SQL Server Agent on completion of job execution.
Sintassi
object
.EnumJobNotifications
as
QueryResults
Parts
- object
Expression that evaluates to an object in the Applies To list.
Prototype (C/C++)
HRESULT EnumJobNotifications(
LPSQLDMOQUERYRESULTS *ppResults);
Returns
The EnumJobNotifications method returns a QueryResults object that contains one result set defined by these columns.
Column name | Data type | Description |
---|---|---|
job_id |
uniqueidentifier |
System-generated identifier for a SQL Server Agent job. |
name |
nvarchar(129) |
Job name. |
notify_level_email |
integer |
Job completion status causing notification by e-mail. Interpret as described in Remarks. |
notify_level_/netsend |
integer |
Job completion status causing notification by network pop-up message. Interpret as described in Remarks. |
notify_level_page |
integer |
Job completion status causing notification by pager. Interpret as described in Remarks. |
Osservazioni
Interpret values returned in value returned in the notify_level_email, notify_level_netsend, and notify_level_page columns using these values.
Value | Description |
---|---|
0 |
Operator not configured for notification by notification method. |
1 |
Operator receives notification of a successful job execution. |
2 |
Operator receives notification of an unsuccessful execution attempt. |
3 |
Operator receives notification regardless of execution outcome. |
The result set returned enumerates all jobs for which an operator will receive notification on execution attempt completion. At least one of the columns notify_level_email, notify_level_netsend, or notify_level_page will contain a non-zero value for all rows in the result set.