Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Threaded View
Sqoop >> mail # user >> How do I select the database when connecting to SQL SERVER ?


Copy link to this message
-
Re: How do I select the database when connecting to SQL SERVER ?
Hey User,

Based on http://technet.microsoft.com/en-us/library/aa342339.aspx it seems
like your connection URL should look like this:
"jdbc:sqlserver://localhost:1433;
databaseName=AdventureWorks;user=UserName;password=*****"
On Thu, Sep 5, 2013 at 6:53 AM, Kallinteris, Christos <
[EMAIL PROTECTED]> wrote:

>  Hello again!****
>
> ** **
>
> ** **
>
> After my previous misadventure and  thanks to Mengwei I have a functioning
> connection to my SQL Server; at least Sqoop doesn’t complain when setting
> up the connection.****
>
> ** **
>
> How do I specify which database on the server to use? I tried putting it
> in the connection string
> ‘jdbc:sqlserver://myserver\myInstance;database=mydatabase;’ but when
> submitting a job to import a table on that database I get ****
>
> ** **
>
> : Exception: java.lang.Throwable Message: Invalid object name
> 'dbo.tblFaelle'. ****
>
> ** **
>
> The table exists and is accessible to the user I use for credentials. The
> most obvious cause to me, is that Sqoop is looking for the table outside
> the database, or am I missing something?****
>
> ** **
>
> Thanks!****
>
> ** **
>
> Chris****
>
> ** **
>
> ------------------------------BEGIN TRACE -------------------------------*
> ***
>
> ** **
>
> Exception has occurred during processing command****
>
> Server has returned exception: Exception: java.lang.Throwable Message:
> GENERIC_JDBC_CONNECTOR_0002:Unable to execute the SQL statement****
>
> Stack trace:****
>
>          at  org.apache.sqoop.connector.jdbc.GenericJdbcExecutor
> (GenericJdbcExecutor.java:59)****
>
>          at  org.apache.sqoop.connector.jdbc.GenericJdbcImportInitializer
> (GenericJdbcImportInitializer.java:155)****
>
>          at  org.apache.sqoop.connector.jdbc.GenericJdbcImportInitializer
> (GenericJdbcImportInitializer.java:48)****
>
>          at  org.apache.sqoop.connector.jdbc.GenericJdbcImportInitializer
> (GenericJdbcImportInitializer.java:37)****
>
>          at  org.apache.sqoop.framework.FrameworkManager
> (FrameworkManager.java:447)****
>
>          at  org.apache.sqoop.handler.SubmissionRequestHandler
> (SubmissionRequestHandler.java:112)****
>
>          at  org.apache.sqoop.handler.SubmissionRequestHandler
> (SubmissionRequestHandler.java:98)****
>
>          at  org.apache.sqoop.handler.SubmissionRequestHandler
> (SubmissionRequestHandler.java:68)****
>
>          at  org.apache.sqoop.server.v1.SubmissionServlet
> (SubmissionServlet.java:44)****
>
>          at  org.apache.sqoop.server.SqoopProtocolServlet
> (SqoopProtocolServlet.java:63)****
>
>          at  javax.servlet.http.HttpServlet (HttpServlet.java:637)****
>
>          at  javax.servlet.http.HttpServlet (HttpServlet.java:717)****
>
>          at  org.apache.catalina.core.ApplicationFilterChain
> (ApplicationFilterChain.java:290)****
>
>          at  org.apache.catalina.core.ApplicationFilterChain
> (ApplicationFilterChain.java:206)****
>
>          at  org.apache.catalina.core.StandardWrapperValve
> (StandardWrapperValve.java:233)****
>
>          at  org.apache.catalina.core.StandardContextValve
> (StandardContextValve.java:191)****
>
>          at  org.apache.catalina.core.StandardHostValve
> (StandardHostValve.java:127)****
>
>          at  org.apache.catalina.valves.ErrorReportValve
> (ErrorReportValve.java:102)****
>
>          at  org.apache.catalina.core.StandardEngineValve
> (StandardEngineValve.java:109)****
>
>          at  org.apache.catalina.connector.CoyoteAdapter
> (CoyoteAdapter.java:293)****
>
>          at  org.apache.coyote.http11.Http11Processor
> (Http11Processor.java:859)****
>
>          at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler
> (Http11Protocol.java:602)****
>
>          at  org.apache.tomcat.util.net.JIoEndpoint$Worker
> (JIoEndpoint.java:489)****
>
>          at  java.lang.Thread (Thread.java:662)****
>
> Caused by: Exception: java.lang.Throwable Message: Invalid object name
> 'dbo.tblFaelle'.****
>
> Stack trace:****
>
>          at  com.microsoft.sqlserver.jdbc.SQLServerException
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB