我有一個EXTERNAL hive表存儲在LZO格式。該表中有一些行,但我無法通過「select *」獲取數據。我的表格格式肯定存在一些問題,但我不知道如何解決這個問題。Hive:select * no result
CREATE EXTERNAL TABLE tableName(
column1 string
)
PARTITIONED BY (
column2 string
)
ROW FORMAT DELIMITED
FIELDS TERMINATED BY '\t'
STORED AS INPUTFORMAT
'com.hadoop.mapred.DeprecatedLzoTextInputFormat'
OUTPUTFORMAT
'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat'
LOCATION
'hdfs://.../tableName'
select count(*) from tableName; //return 1
select * from tableName; //return nothing
select column1, column2 from tableName group by column1,column2; //return data1 data2
select * from tableName where column2='data2'; //return nothing
只有 「SELECT *」 返回任何結果。也許「select *」不是通過map-reduce執行的?
[gzip文件的負載csv文件到配置單元(的可能的複製https://stackoverflow.com/questions/44450451/load -csv-文件的,用gzip文件到蜂巢) –