Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/neo4j/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何使用;定义“;Microsoft.Hadoop.WebHCat.Protocol.WebHCatHttpClient.CreateHiveJob的参数?_Hive_Azure Hdinsight_Hcatalog - Fatal编程技术网

如何使用;定义“;Microsoft.Hadoop.WebHCat.Protocol.WebHCatHttpClient.CreateHiveJob的参数?

如何使用;定义“;Microsoft.Hadoop.WebHCat.Protocol.WebHCatHttpClient.CreateHiveJob的参数?,hive,azure-hdinsight,hcatalog,Hive,Azure Hdinsight,Hcatalog,我猜defines允许向配置单元查询传递参数,但我还没有找到任何文档或使用示例。如何在查询中使用这些参数?我正在使用powershell中的defines参数,但希望它能帮助您 首先,在PowerShell脚本中,我编写了如下内容: [HashTable] $defines $defines = @{} $defines.Add("someContainerUrl",${someContainerUrl}) ADD FILES ${hiveconf:someContainerUrl}/

我猜
defines
允许向配置单元查询传递参数,但我还没有找到任何文档或使用示例。如何在查询中使用这些参数?

我正在使用powershell中的defines参数,但希望它能帮助您

首先,在PowerShell脚本中,我编写了如下内容:

[HashTable] $defines
$defines = @{}
$defines.Add("someContainerUrl",${someContainerUrl})
ADD FILES
    ${hiveconf:someContainerUrl}/SomeFile.exe;
然后,在调用HDInsight时,我使用了这个新的defines变量:

$jobDef = New-AzureHDInsightHiveJobDefinition -Query $hiveQuery -JobName $jobName -Defines $defines -StatusFolder "/JobStatus/Hive"
$hiveJob = Start-AzureHDInsightJob –Cluster $clusterName –JobDefinition $jobDef
然后在我的配置单元代码中,我可以使用此定义变量,例如:

[HashTable] $defines
$defines = @{}
$defines.Add("someContainerUrl",${someContainerUrl})
ADD FILES
    ${hiveconf:someContainerUrl}/SomeFile.exe;
我认为这篇文章也可能对您有所帮助: