Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Basic operation of Sqoop ETL tool

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

Basic operation of Sqoop ETL tool View sqoop command description

Sqoop help

View the instructions for a command:

Sqoop cammond-help

From orange,mysql to hdfs

Sqoop import-connect jdbc:oracle:thin:@192.168.1.254:1521:orcl-username bd_user-password bd_user-table GS_B_GY_DWCPNYXHBJG_S-target-dir'/ user//'-m 1

Sqoop import-connect jdbc:mysql://192.168.1.232:3307/bigdatamanager-username root-password root-table gbi_pd_log-target-dir / user/hehe-m 1

From oracle,mysql to hive

Sqoop import-all-tables-- connect jdbc:oracle:thin:@192.168.1.232:14231:xe-- username bhl_user-- password bhl_user-- hive-database bhl_user-M1-- create-hive-table-- hive-import-hive-overwrite

Sqoop import-connect jdbc:oracle:thin:@192.168.1.232:14231:xe-username bhl_user-password bhl_user-table BD_ECO_TX_2015_0516

Sqoop import-- connect jdbc:oracle:thin:@192.168.1.232:14231:xe-- username bhl_user-- password bhl_user-- table BD_ECO_TX_2015_0516-hive-import-hive-database bhl_user-m 1 (the screenshot of the oracle connection will not be written here, here is the test of mysql)

=

List the databases:

Sqoop list-databases-connect jdbc:mysql://192.168.1.232:3307/bigdatamanager-username root-password root

List the tables in the bigdatamanager database

Sqoop list-tables-connect jdbc:mysql://192.168.1.232:3307/bigdatamanager-username root-password root

From mysql to hive

Sqoop import-connect jdbc:mysql://192.168.1.232:3307/bigdatamanager-username root-password root-table insurance_yearcost-hive-import

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report