Get-​Azure​Sql​Job​Trigger

Gets one or multiple job triggers.

Syntax

Get-AzureSqlJobTrigger
   [[-AzureSqlJobConnection] <AzureSqlJobConnection>]
   [-JobName <String>]
   [-ScheduleName <String>]
   [<CommonParameters>]

Description

The Get-AzureSqlJobTrigger cmdlet gets one or multiple job triggers. A job trigger is a mapping of job to schedules. In accordance to the schedule definition, job runs are triggered for each job or schedule mapping.

Examples

Example 1: Get all job triggers using the specified job name

PS C:\>Get-AzureSqlJobTrigger -JobName "MyJob"
JobName                                              ScheduleName                                                                                     Enabled
-------                                              ------------                                                                                     -------
MyJob                                                MyOneMinuteIntervalSchedule                                                                         True

This command gets all job triggers under the job named MyJob.

Example 2: Get all job triggers using a specified job schedule

PS C:\>Get-AzureSqlJobTrigger -ScheduleName "MyOneMinuteIntervalSchedule"
JobName                                              ScheduleName                                                                                     Enabled
-------                                              ------------                                                                                     -------
MyJob                                                MyOneMinuteIntervalSchedule                                                                         True

This command gets all job triggers using the schedule named MyOneMinuteIntervalSchedule.

Example 3: Get all triggers defined in the system

PS C:\>Get-AzureSqlJobTrigger
JobName                                              ScheduleName                                                                                     Enabled
-------                                              ------------                                                                                     -------
System Job: telemetry                                System schedule: telemetry                                                                          True
System Job: heartbeat                                System schedule: heartbeat                                                                          True
System Job: cleanup                                  System schedule: cleanup                                                                            True
MyJob                                                MyOneMinuteIntervalSchedule                                                                         True

This command gets all triggers defined in the system.

Optional Parameters

-AzureSqlJobConnection

Specifies the connection state object for the job. You can get the connection state object through the New-AzureSqlJobConnection cmdlet. If you do not specify this parameter, the connection state is used from a prior call to the Use-AzureSqlJobConnection cmdlet.

Type:AzureSqlJobConnection
Position:1
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-JobName

Specifies the job name. If you specify this parameter, this cmdlet returns triggers that are bounded to the provided job name.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ScheduleName

Specifies the schedule name. If you specify this parameter, this cmdlet returns triggers that are bounded to the provided schedule name.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False