Advertisement
Guest User

Untitled

a guest
Mar 1st, 2016
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.13 KB | None | 0 0
  1. import
  2. --connect
  3. jdbc:oracle:thin:@hostname:port:sid
  4. --username
  5. user
  6. --password
  7. password1
  8. --query
  9. 'SELECT col1, col2, ..., col18,"'pivotedcol1'", ..., "'pivotedcol21'"
  10. FROM (SELECT col1, ..., col18, DEFINITIONS,
  11. to_char(to_date(TIME),'DD.MM.YY', 'YYYY-MM-DD')
  12. FROM table1
  13. LEFT OUTER JOIN table2
  14. ON table2.colX = table1.colX
  15. LEFT OUTER JOIN table3
  16. ON table2.colY = table3.colX
  17. LEFT OUTER JOIN table4
  18. ON table4.colX = table1.colX
  19. LEFT OUTER JOIN table5
  20. ON table5.colX = table4.colY
  21. LEFT OUTER JOIN table6
  22. ON table5.colY = table6.colX
  23. LEFT OUTER JOIN table7
  24. ON table7.colX = table1.colX
  25. LEFT OUTER JOIN table8
  26. ON table7.colY = table8.colX
  27. WHERE ROWNUM <= 45000 AND $CONDITIONS)
  28. PIVOT (MAX(TIME) FOR DEFINITIONS IN ('pivotedcol1', ..., 'pivotedcol21'))'
  29. --as-avrodatafile
  30. --verbose
  31. --target-dir
  32. directory/freeform
  33.  
  34. sqoop --options-file file.props
  35.  
  36. ERROR sqoop.Sqoop: Error while expanding arguments java.lang.Exception: Multiline quoted strings not supported in file(file.props)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement