我正在尝试导入数据表从mssql到hbase与sqoop,我使用C#语言。我一直在关注this article
我将数据导入hbase的代码命令:
connectionstring:
connectionString = "jdbc:sqlserver://" + sqlDatabaseServerName + ";user=" + sqlDatabaseLogin + ";password=" + sqlDatabaseLoginPassword + ";database=" + sqlDatabaseDatabaseName;sqoop命令:
"import --connect " + connectionString + " --table " + tableName + " -hbase-create-table –hbase-table TestTableHBase -column-family PostID -hbase-row-key PostID -m 1"我收到了一个成功的响应,但它不起作用。
发布于 2020-05-29 18:04:50
For MYSQL to HBASE:
您可以使用以下命令将Mysql表导入到HBase表中:
sqoop import --connect jdbc:mysql://localhost/emp --username root --password cloudera --table employee --hbase-table Academp --column-family emp_id --hbase-row-key id -m 1参考: How to Import Table from MySQL to HBase
用于SQL SERVER到HBASE的
您可以使用以下命令将SQL server表导入到HBase表中:
sqoop import --connect "jdbc:sqlserver://hostname:1433;database=db_name;username=sqoop;password=???" --hbase-create-table --hbase-table table_name_in_hbase --column-family cf_name --hbase-row-key my_ID --table tablename_in_sql_server -m 1https://stackoverflow.com/questions/61891343
复制相似问题