Guest User

Untitled

a guest
May 3rd, 2018
256
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.52 KB | None | 0 0
  1. #!/usr/bin/env python
  2. #-*-encoding:utf-8 -*-
  3. from subprocess import call
  4. #默认导入到default
  5. call("sqoop import --connect jdbc:mysql://10.0.2.248:3306/test?zeroDateTimeBehavior=CONVERT_TO_NULL --username root --password hive123 --table op --hive-import --hive-overwrite -m 2",shell=True)
  6. #指定hive的库
  7. call("sqoop import --connect jdbc:mysql://10.0.2.248:3306/test?zeroDateTimeBehavior=CONVERT_TO_NULL --username root --password hive123 --table op --hive-import --hive-overwrite --hive-database bigdata -m 2",shell=True)
Add Comment
Please, Sign In to add comment