When storing a Hive table in text format, for example, in this table:
CREATE EXTERNAL TABLE clustered_item_info
(
country_id int,
item_id string,
productgroup int,
category string
)
PARTITIONED BY (cluster_id int)
ROW FORMAT DELIMITED FIELDS TERMINATED BY '\t'
LOCATION '${hivevar:table_location}';
Fields with zero values are represented as strings "\ n", also for numbers NaN are represented as strings "NaN".
Does Hive provide a way to specify a custom string to represent these special values?
I would like to use empty lines instead of "\ n" and 0 instead of "NaN". I know this substitution can be done with streaming, but is there any way to it using Hive instead of writing additional code?
Additional info: I use Hive 0.8, if that matters ...