You have a file personal_data.txt in the HDFS directory with 100 records. You want to see only the first 5 records from the employee.txt file. How will you do this?
Answer Posted / Vipul Negi
To view the first 5 records of an HDFS file using Pig, you would need to load the data into a Pig relation and then limit the number of rows displayed. Here's an example: `LOAD personal_data.txt INTO employee; LIMIT employee 5; DUMP employee;`
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers