Explain jsonloader, jsonstorage functions in pig?



Explain jsonloader, jsonstorage functions in pig?..

Answer / Jitendra Kumar Sharma

"jsonloader" and "jsonstorage" are UDFs (User Defined Functions) provided by Apache Pig for reading and writing JSON files. They allow you to easily manipulate data stored in JSON format.nnExample usage:n`REGISTER <path_to_udfs>/JSONLoader.jar; REGISTER <path_to_udfs>/JSONStorage.jar;ndata = FOREACH jsonloader('<input_file>') GENERATE *;nSTORED data INTO '<output_file>' USING jsonstorage();`

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Apache Pig Interview Questions

Explain pigstorage function?

1 Answers  


How will you merge the contents of two or more relations and divide a single relation into two or more relations?

1 Answers  


How do you write comments in pig scripts?

1 Answers  


Why is pig used in hadoop?

1 Answers  


why should we use 'filters' in pig scripts?

1 Answers  


How do you handle compression in pig?

1 Answers  


What are the different Relational Operators available in pig language?

1 Answers  


Whether Pig Latin language is case-sensitive or not?

1 Answers  


what is pig?

1 Answers  


Explain about the execution plans of a Pig Script? Or Differentiate between the logical and physical plan of an Apache Pig script?

1 Answers  


What is the use of having Filters in Apache Pig ?

1 Answers  


What is the bag?

1 Answers  


Categories