Stop-AzureSqlJobExecution

Stops a job execution.

Syntax

Stop-AzureSqlJobExecution
    -InputObject <JobExecutionInfo[]>
    [[-AzureSqlJobConnection] <AzureSqlJobConnection>]
    [<CommonParameters>]
Stop-AzureSqlJobExecution
    -JobExecutionId <Guid[]>
    [[-AzureSqlJobConnection] <AzureSqlJobConnection>]
    [<CommonParameters>]
Stop-AzureSqlJobExecution
    -JobName <String[]>
    [[-AzureSqlJobConnection] <AzureSqlJobConnection>]
    [<CommonParameters>]

Description

The Stop-AzureSqlJobExecution cmdlet stops a job execution. The system subsequently attempts to cancel the job.

Examples

Example 1: Stop a job execution

PS C:\>Stop-AzureSqlJobExecution -JobExecutionId 07981e74-5235-48a6-b24e-b5beb16a149a

This command stops the execution of a job.

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
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-InputObject

Specifies the JobExecutionInfo object(s) to be stopped. JobExecutionInfo objects can be obtained using the Get-AzureSqlJobExecution cmdlet.

Type:JobExecutionInfo[]
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-JobExecutionId

Specifies the job execution ID.

Type:Guid[]
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-JobName

Specifies the name of the job.

Type:String[]
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False