Hello!
I am using the following code to try to import data from mysql database to
Hbase:
SqoopOptions options = new SqoopOptions();
        options.setConnectString("jdbc:mysql://localhost:3306/testDb");
        options.setTableName("student");
        //options.setWhereClause("id>10");     // this where clause works
when importing whole table, ie when setTableName() is used
        options.setUsername("root");
        options.setPassword("");
        //options.setDirectMode(true);    // Make sure the direct mode is
off when importing data to HBase
        options.setNumMappers(8);         // Default value is 4


        // HBase options
        options.setHBaseTable("HBASE_student");
        options.setHBaseColFamily("colFamily");
        options.setCreateHBaseTable(true);    // Create HBase table, if it
does not exist
        options.setHBaseRowKeyColumn("stdId");

        @SuppressWarnings({ "unused" })
        int ret = new ImportTool().run(options);

Could you please tell me which jars (plz be specific with the versions) I
have to include in my class path. I have tried a number of combination but
in the end I end up in a conflict.

Regards.
  • Sqoop Import Us... Nauman Zahid

Reply via email to