0
我創建了一個表後選擇例外:「不是一個文件」插入成功
DROP TABLE IF EXISTS sampleout;
CREATE EXTERNAL TABLE sampleout(
id bigint,
LNG FLOAT,
LAT FLOAT,
GMTDateTime TIMESTAMP,
calculatedcolumn FLOAT
)
ROW FORMAT DELIMITED FIELDS TERMINATED BY ','
STORED AS TEXTFILE LOCATION 'wasb://[email protected]/';
然後我得到了這個查詢成功:
INSERT into TABLE sampleout select *, 0 as calculatedcolumn from sampletable
sampleout
是一樣的,除了sampletable
爲額外的列calculatedcolumn
。插入成功後,我打開blob存儲並打開文本文件以驗證數據是否位於指定的文本文件位置。
但是......
select * from sampleout limit 10
返回以下錯誤:
Logging initialized using configuration in file:/C:/apps/dist/hive-0.13.0.2.1.12.1-0003/conf/hive-log4j.properties
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/C:/apps/dist/hadoop-2.4.0.2.1.12.1-0003/share/hadoop/common/lib/slf4j-log4j12-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/C:/apps/dist/hbase-0.98.0.2.1.12.1-0003-hadoop2/lib/slf4j-log4j12-1.6.4.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]
OK
Failed with exception java.io.IOException:java.io.IOException: Not a file: wasb://[email protected]/hive
Time taken: 3.032 seconds
是怎麼回事,我可以順利插入,但不能從表中選擇?請注意,該錯誤顯示將'/ hive'添加到create中指定的文本文件位置。