Detailed example of LOAD
Tuesday, February 22, 2011
7:50 PM
Suppose that test.dat contains
Alva 20
George 30
Joe 10 
And that we execute
$ pig -x local 
grunt> test = LOAD 'test.dat' USING PigStorage(' ') AS (name, toys); 
grunt> DUMP test;
… some diagnostic output removed...
(Alva,20)
(George,30)
(Joe,10)
grunt> DESCRIBE test;  
test: {name: bytearray,toys: bytearray}
grunt> STORE test INTO 'out.dat' USING PigStorage();
grunt> 
Note that:
Without further information, everything is a bytearray.
STORE creates a duplicate of the input file 'test.dat', space-delimited. 