Last active
May 3, 2018 17:24
-
-
Save prasku5/49a1852931a3ef72f0a0a0970eca4970 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sqoop import \ | |
--connect jdbc:mysql://localhost/source_database_name \ (This is the path to access the Source DB using JDBC Driver) | |
--username <username> \ (Source Database Username) | |
--password <password> \ (Source Database password) | |
--database source_database_name \ (The database name will become folder name in target HDFS ) | |
--table Source_table_name \ (This will store the files in .gz compression which is default) | |
--hive-import \ (This will import the data imported in HDFS as Hive table automatically) | |
--hive-table <table name>\ (This will be the name of hive table of our choice instead of default MySQL table name) | |
--hive-overwrite \ (This will overwrite the existing file in HDFS and recreate new table in Hive) | |
-m 4 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment