Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Question on multiple delimiters. Single quote n comma. treat anything in single quote as single colu

Question on multiple delimiters. Single quote n comma. treat anything in single quote as single colu

New Contributor
I'm new to to Pig. I have a problem - My input textfile.txt -> aaaa,bbbb,cccc aaaa,'xxxx,yyyy',zzzz qqqq,wwww,eeee Output should have three columns only. Anything in single quotes should be treated as single column. 'xxxx,yyyy' to be treated as one field data only. If I use below - A = load textfile.txt PigStorage(,) as (col1:chararray, col2:chararray) I get - (aaaa,bbbb,cccc) (aaaa,'xxxx,yyyy') (qqqq,wwww,eeee) Please help me with this.
1 REPLY 1
Highlighted

Re: Question on multiple delimiters. Single quote n comma. treat anything in single quote as single

New Contributor

i mean, i am using -

A = load textfile.txt PigStorage(,) as (col1:chararray, col2:chararray, col3:chararray)