I'm trying to change the existing Hive external table delimiter from comma ,
to ctrl+A
character by using Hive ALTER TABLE statement
ALTER TABLE table_name SET SERDEPROPERTIES ('field.delim' = '\u0001');
After the DDL I could see changes
show create table table_name
But when I select from Hive, the values are all NULL (underlying files in HDFS are changed to have ctrl+A delimiter).
I have repaired the table also by using msck.
Only way to see the data is dropping and re-creating the external table, can anyone please help me to understand the reason.
Table Syntax :
CREATE EXTERNAL TABLE `table_name`( col1, col2, col3) PARTITIONED BY ( `ing_year` int, `ing_month` int, `ing_day` int) ROW FORMAT DELIMITED FIELDS TERMINATED BY ',' LINES TERMINATED BY '\n' STORED AS INPUTFORMAT 'org.apache.hadoop.mapred.TextInputFormat' OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat' LOCATION 'hdfs://location/'
Hive
orImpala
? - cheseaux