Support Questions
Find answers, ask questions, and share your expertise
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Hortonworks Sandbox - SQL Server Connection

Hortonworks Sandbox - SQL Server Connection

New Contributor

Hello Folks,

I have installed Hortonworks sandbox 2.4 and SQL server database on my machine. SQL server log in is with windows authentication. I want to import a table from sql server into hdfs on sandbox. I am using sqoop for the very first time. Can you please guide me on how to initialize SQOOP and import data.


Re: Hortonworks Sandbox - SQL Server Connection

Super Guru


I would start with sqoop user guide here. @Artem Ervits wrote a how to tutorial on sqoop here. For sqoop basic usage start here.

Lastly tutorial on import data from sql server to hortonworks sandbox here. In general I find this blog very useful on importing from sqlserver.

      sqoop import --connect jdbc:sqlserver://sqlserver-name \
          --username <username> \
          --password <password> \
          --driver   <driver-manager-class> \
          --table    <table-name> \
          --target-dir  <target-folder-name>

      sqoop import --connect "jdbc:sqlserver://labDB;database=demo" \
           --username sqoop  \
           --password simp1e \
           --driver \
           --table    "dbo.customer" \
           --target-dir  "/tmp/dbo-customer"

Don't have an account?
Coming from Hortonworks? Activate your account here