I am able to use Double Quotes in following query ->
$subscriptionName = "***"
$clusterName = "***"
$queryString = "SELECT city FROM logs WHERE city =""New York"";"
Use-AzureHDInsightCluster $clusterName
Invoke-Hive -Query $queryString
But I am not able to use Quotes in following PowerShell Comamnds -
$subscriptionName = "***"
$storageAccountName = "***"
$containerName = "***"
$clusterName = "***"
$queryString = "SELECT city FROM logs WHERE city =""New York"";"
$hiveJobDefinition = New-AzureHDInsightHiveJobDefinition -Query $queryString
Select-AzureSubscription $subscriptionName
$hiveJob = Start-AzureHDInsightJob -Cluster $clusterName -JobDefinition $hiveJobDefinition
Wait-AzureHDInsightJob -Job $hiveJob -WaitTimeoutInSeconds 36000
Get-AzureHDInsightJobOutput -Cluster $clusterName -JobId $hiveJob.JobId -StandardOutput
It is giving me following error -
Please give me some information why is this sporadic behavior. Both implementations creates jobs, then why one implementation accepting double quotes and other not.
See Question&Answers more detail:os