Hive: What is wrong with this regex? -


i trying insert data hive table input file csv formatted follows:-

stringa,"stringb","stringc",stringd,"stringe","stringf" 

where stringf has delimiter ',' within itself.

i tried following input regex null values in table:-

create external table tablname(col1 string, col2 string, col3 string, col4 string, col5 string, col6 string)     row format serde 'org.apache.hadoop.hive.contrib.serde2.regexserde' serdeproperties ("input.regex" =  (([^ ]*),(\"[^\"]\"),(\"[^\"]\"),([^ ]*),(\"[^\"]\"),(\"[^\"]\")) location '/path/to/data' 

a [ ] expression defines class of characters. if don't specify quantifier, means: precisely 1 occurrences of character of defined class. therefore, expression presumably has this:

(([^ ]*),(\"[^\"]*\"),(\"[^\"]*\"),([^ ]*),(\"[^\"]*\"),(\"[^\"]*\")) 

Comments