Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- use testhadoop;
- CREATE TABLE employee(
- empid INT(2),
- empname varchar(20),
- salray int (6)
- );
- INSERT INTO employee VALUES
- (1,'emp1',15000),
- (1,'emp1',15000),
- (2,'emp2',12200),
- (3,'emp3',99999),
- (4,'emp4',17687),
- (5,'emp5',45788);**strong text**
- cd $SQOOP_HOME
- bin/sqoop import --connect jdbc:mysql://localhost/testhadoop --username root -P --table employee --hbase-table employeeHBase
- --column-family info --hbase-row-key empid --hbase-create-table -m 1
- 13/12/05 17:40:47 INFO manager.MySQLManager: Setting zero DATETIME behavior to convertToNull (mysql)
- 13/12/05 17:40:47 ERROR tool.ImportTool: Error during import: HBase jars are not present in classpath, cannot import to HBase!
- export HBASE_HOME=/usr/lib/hbase
- sqoop import ...
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement