AnsweredAssumed Answered

Loading data into MapR table using PIG?

Question asked by rameshg on Mar 25, 2015
Latest reply on Mar 25, 2015 by rameshg
Hi All,
I'm trying to load the data into MapR table using PIG.

Here are the steps I followed for the same.

In the hbase shell created a table by specifying the path of the table

    create '/maprfs/path/hbase_tablename', 'colfam1','colfam2','colfam3'

table created successfully.
Started PIG grunt shell.
Now I added few jars to the path of the pig.

    register /tmp/new/mapr-hbase-1.0.3-mapr-3.0.2.jar;
    register /tmp/new/piggybank-0.14.0.jar;
    register /tmp/new/guava-11.0.2.jar;

Loaded the data into a variable

    a = LOAD 'maprfs/path/inputdatafile' USING PigStorage(',') AS (
    cf1,
    cf2,
    cf3
    );

then I dumped the data and I'm able to see the data of inputdatafile on the console.
Now trying to store the data in earlier created MapR table(hbase table) using store.
Any suggestion how to store the data in a to MapR table (hbase_table)

Thanks in advance.


Outcomes