Enrollments closing soon for Post Graduate Certificate Program in Applied Data Science & AI By IIT Roorkee | 3 Seats Left
Apply NowLogin using Social Account
     Continue with GoogleLogin using your credentials
[Pig - Load]
LOAD operator loads the data from the file system.
load '/data/NYSE_dividends';
Tab will be the default separator if we do not specify a separator while loading the data. Pig loads the values and automatically guesses the datatype
load '/data/NYSE_dividends' using PigStorage(',');
[Pig - Store / Dump]
Store operator is used to store the data to HDFS and other storages.
Dump prints the value on the screen. It is used for debugging.
Code
divs = LOAD '/data/NYSE_dividends';
divs = LOAD '/data/NYSE_dividends' USING PigStorage(',');
divs = LOAD '/data/NYSE_dividends' AS (name: chararray, stock_symbol: chararray, date: datetime, dividend: float);
Taking you to the next exercise in seconds...
Want to create exercises like this yourself? Click here.
Loading comments...