Home:ALL Converter>Error with sqoop import from mysql to hbase

Error with sqoop import from mysql to hbase

Ask Time:2017-07-16T02:42:35         Author:Manasa C

Json Formatter

I started learning sqoop recently with cloudera CDH5 VM.

I created mysql table from a CSV file having columns baseid, date, cars, kms.

  • Database used: mysql
  • Table created: uberdata

In hbase shell, I created with table name --myuberdatatable and column family --uber_details.

I checked with scan command and got to see empty table with 0 rows.

To Transfer the data from my mysql to hbase:

sqoop import jdbc:mysql://localhost/mysql --username root --password cloudera 
             --table uberdata --hbase-table myuberdatatable --column-family trip_details 
             --hbase-row-key base -m 1**

I am getting the following error:

Syntax error, unexpected tIdentifier

with a mark showing before jdbc.

It could be small error but tried to find solution in stackoverflow.

Can anyone help to fix this. Thanks in advance...

Author:Manasa C,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/45121577/error-with-sqoop-import-from-mysql-to-hbase
yy