Pergunta

CREATE TABLE test1 (Column1 string) ROW FORMAT DELIMITED FIELDS TERMINATED BY ',';

LOAD DATA INPATH 'asv://hivetest@mystorageaccount.blob.core.windows.net/foldername' OVERWRITE INTO TABLE test1 ;

Loading the data generates the following error:

FAILED: Error in semantic analysis: Line 1:18 Path is not legal ''asv://hivetest@mystorageaccount.blob.core.windows.net/foldername'': Move from: asv://hivetest@mystorageaccount.blob.core.windows.net/foldername to: asv://hdi1@hdinsightstorageaccount.blob.core.windows.net/hive/warehouse/test1 is not valid. Please check that values for params "default.fs.name" and "hive.metastore.warehouse.dir" do not conflict.

The container hivetest is not my default HDInsight container. It is even located on a different storage account. However, the problem is probably not with the account credentials, as I have edited core-site.xml to include mystorageaccount.

How can I load data from a non-default container?

Foi útil?

Solução

Apparently it's impossible by design to load data into a Hive table from a non-default container. The workaround suggested by the answer in the link is using an external table.

I was trying to use a non-external table so I can take advantage of partitioning, but apparently it's possible to partition even an external table, as explained here.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top