Alert.JobName Property

 

Applies To: SQL Server 2016 Preview

Gets or sets the name of the SQL Server Agent job that is run in response to the alert being raised.

Namespace:   Microsoft.SqlServer.Management.Smo.Agent
Assembly:  Microsoft.SqlServer.Smo (in Microsoft.SqlServer.Smo.dll)

Syntax

[SfcPropertyAttribute(SfcPropertyFlags.None | SfcPropertyFlags.Standalone | SfcPropertyFlags.Matrix)]
public string JobName { get; }
public:
[SfcPropertyAttribute(SfcPropertyFlags::None | SfcPropertyFlags::Standalone | SfcPropertyFlags::Matrix)]
property String^ JobName {
    String^ get();
}
[<SfcPropertyAttribute(SfcPropertyFlags.None | SfcPropertyFlags.Standalone | SfcPropertyFlags.Matrix)>]
member JobName : string with get
<SfcPropertyAttribute(SfcPropertyFlags.None Or SfcPropertyFlags.Standalone Or SfcPropertyFlags.Matrix)>
Public ReadOnly Property JobName As String

Property Value

Type: System.String

A String value that specifies the name of the job that is run in response to the raised alert.

Examples

Legacy Code Example

Scheduling Automatic Administrative Tasks in SQL Server Agent

See Also

Alert Class
Microsoft.SqlServer.Management.Smo.Agent Namespace
Automated Administration Tasks (SQL Server Agent)
sp_add_alert (Transact-SQL)

Return to top