New-​Azure​Rm​Stream​Analytics​Job

Creates or updates a Stream Analytics job.

Syntax

New-AzureRmStreamAnalyticsJob
   [-ResourceGroupName] <String>
   [[-Name] <String>]
   [-File] <String>
   [-Force]
   [-PipelineVariable <String>]
   [-Confirm]
   [-WhatIf]
   [<CommonParameters>]

Description

The New-AzureRmStreamAnalyticsJob cmdlet creates a new Stream Analytics job in Azure or updates the definition of an existing specified job. The name of the job can be specified in the .JSON file or on the command line. If both are specified, the name on command line must match the name in the file.

If you specify a job name that already exists and do not specify the Force parameter, the cmdlet will ask whether or not to replace the existing job.

If you specify the Force parameter and specify an existing job name, the job definition will be replaced without confirmation.

Examples

EXAMPLE 1: Create a job

PS C:\>New-AzureRmStreamAnalyticsJob -ResourceGroupName "StreamAnalytics-Default-West-US" -File "C:\JobDefinition.json"

This command creates a job from the definition in JobDefinition.json. If an existing job with the specified name in the job definition file is already defined, the cmdlet will ask whether or not to replace it.

EXAMPLE 2: Replace a job definition

PS C:\>New-AzureRmStreamAnalyticsJob -ResourceGroupName "StreamAnalytics-Default-West-US" -File "C:\JobDefinition.json" -Name "StreamingJob" -Force

This command replaces the job definition for StreamingJob without confirmation.

Required Parameters

-File

Specifies the path to a JSON file that contains the JSON representation of the Azure Stream Analytics job to create.

Type:String
Position:2
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ResourceGroupName

Specifies the name of the resource group to which the Azure Stream Analytics job should belong.

Type:String
Position:0
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Optional Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False
-Force

Forces the command to run without asking for user confirmation.

Type:SwitchParameter
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Name

Specifies the name of the Azure Stream Analytics job to create.

Type:String
Position:1
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-PipelineVariable

Not Specified

Type:String
Aliases:pv
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False

Outputs

Microsoft.Azure.Commands.StreamAnalytics.Models.PSJob