"Error: List index out of range" in HIVE while displaying a recently created empty table
"Error: List index out of range" in HIVE while displaying a recently created empty table
我正在使用 virtual box 运行cloudera v5.4.2-0。
我按照在线课程的说明使用以下 HIVEQL 创建了一个空 table:
create table sales_all_years (RowID smallint, OrderID int, OrderDate date, OrderMonthYear date, Quantity int, Quote float, DiscountPct float, Rate float, SaleAmount float, CustomerName string, CompanyName string, Sector string, Industry string, City string, ZipCode string, State string, Region string, ProjectCompleteDate date, DaystoComplete int, ProductKey string, ProductCategory string, ProductSubCategory string, Consultant string, Manager string, HourlyWage float, RowCount int, WageMargin float)
partitioned by (yr int) -- partitioning
row format serde 'com.bizo.hive.serde.csv.CSVSerde'
stored as textfile;
我做了一些实验,发现 table 分区导致了错误,但我无法找出原因。
P.S。我对此有点陌生。对不起,如果我的问题格式有点不对
问题可能出在 com.bizo.hive.serde.csv.CSVSerde
。尝试使用不同的 SerDe 创建 table,例如
ROW FORMAT SERDE 'org.apache.hadoop.hive.serde2.OpenCSVSerde'
WITH SERDEPROPERTIES (
"separatorChar" = ",",
"quoteChar" = "'",
"escapeChar" = "\"
)
STORED AS TEXTFILE
或者只是带有相应分隔符的文本文件
ROW FORMAT DELIMITED
FIELDS TERMINATED BY ','
STORED AS TEXTFILE
我正在使用 virtual box 运行cloudera v5.4.2-0。 我按照在线课程的说明使用以下 HIVEQL 创建了一个空 table:
create table sales_all_years (RowID smallint, OrderID int, OrderDate date, OrderMonthYear date, Quantity int, Quote float, DiscountPct float, Rate float, SaleAmount float, CustomerName string, CompanyName string, Sector string, Industry string, City string, ZipCode string, State string, Region string, ProjectCompleteDate date, DaystoComplete int, ProductKey string, ProductCategory string, ProductSubCategory string, Consultant string, Manager string, HourlyWage float, RowCount int, WageMargin float)
partitioned by (yr int) -- partitioning
row format serde 'com.bizo.hive.serde.csv.CSVSerde'
stored as textfile;
我做了一些实验,发现 table 分区导致了错误,但我无法找出原因。
P.S。我对此有点陌生。对不起,如果我的问题格式有点不对
问题可能出在 com.bizo.hive.serde.csv.CSVSerde
。尝试使用不同的 SerDe 创建 table,例如
ROW FORMAT SERDE 'org.apache.hadoop.hive.serde2.OpenCSVSerde'
WITH SERDEPROPERTIES (
"separatorChar" = ",",
"quoteChar" = "'",
"escapeChar" = "\"
)
STORED AS TEXTFILE
或者只是带有相应分隔符的文本文件
ROW FORMAT DELIMITED
FIELDS TERMINATED BY ','
STORED AS TEXTFILE