Support Questions
Find answers, ask questions, and share your expertise

Piglatin to dump nested json data

Piglatin to dump nested json data

New Contributor



May you please help in the following problem.


My problem is to dump nested json schema


and i also want to manipulate one column(text column: to remove \n) 


but i want to solve the first problem first. 


REGISTER hdfs://***;
REGISTER hdfs://***;

a = load '/user/maxxx/data/test.json' using JsonLoader('filter_level:chararray, retweeted_status:tuple(contributors:chararray, text:chararray, geo:chararray, retweeted:chararray, in_reply_to_screen_name:chararray, possibly_sensitive:chararray, truncated:chararray, lang:chararray), truncated:chararray)');

c = foreach a generate filter_level, retweeted_status:tuple(contributors, text);

dump c;


Re: Piglatin to dump nested json data

Master Collaborator

Hello, I have moved this thread to the Pig discussion board in the hopes that someone in here can assist you.  Thank you!