我有一个数据集,其中使用双冒号 (
数据结构如下:
::
) 作为分隔符。如何在Hive中使用正则表达式serde来解析数据,以便可以将其导入到表中?数据结构如下:
userId::movieId::rating::time
当前我正在使用这个查询语句,但对于选择语句却返回空值:
create table rating_regex(userId string,movieId string,rating string,time string) row format serde 'org.apache.hadoop.hive.contrib.serde2.RegexSerDe' with serdeproperties(
"input.regex" = "::"
) stored as textfile