lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From PeterKerk <vettepa...@hotmail.com>
Subject Unable to load com.microsoft.sqlserver.jdbc.SQLServerDriver
Date Fri, 09 Aug 2013 13:34:14 GMT
I'm getting this error when trying to user Data Import Handler via URL:
http://localhost:8983/solr/1001/dataimport?command=full-import


Caused by: java.lang.ClassNotFoundException: Unable to load
com.microsoft.sqlser
ver.jdbc.SQLServerDriver or
org.apache.solr.handler.dataimport.com.microsoft.sql
server.jdbc.SQLServerDriver
        at
org.apache.solr.handler.dataimport.DocBuilder.loadClass(DocBuilder.ja
va:911)
        at
org.apache.solr.handler.dataimport.JdbcDataSource.createConnectionFac
tory(JdbcDataSource.java:112)
        ... 12 more
Caused by: org.apache.solr.common.SolrException: Error loading class
'com.micros
oft.sqlserver.jdbc.SQLServerDriver'
        at
org.apache.solr.core.SolrResourceLoader.findClass(SolrResourceLoader.
java:464)
        at
org.apache.solr.core.SolrResourceLoader.findClass(SolrResourceLoader.
java:396)
        at
org.apache.solr.handler.dataimport.DocBuilder.loadClass(DocBuilder.ja
va:901)
        ... 13 more
Caused by: java.lang.ClassNotFoundException:
com.microsoft.sqlserver.jdbc.SQLSer
verDriver
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.net.FactoryURLClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Unknown Source)
        at
org.apache.solr.core.SolrResourceLoader.findClass(SolrResourceLoader.
java:448)


In my data-config I have:

<dataSource driver="com.microsoft.sqlserver.jdbc.SQLServerDriver"
url="jdbc:sqlserver://localhost:1433;databaseName=1001" user="username"
password="password" />

placed sqljdbc4.jar in folder: \solr-4.3.1\example\lib\

in my solrconfig.xml I have:
  <lib dir="../../../../dist/" regex="solr-dataimporthandler-.*\.jar" />
  <lib dir="../../../dist/" regex="sqljdbc4\.jar" />	
  
My java version is 1.6.0_29  

In my <SOLR_HOME>/solr.xml I have: <solr persistent="true" sharedLib="lib">


How to fix this?



--
View this message in context: http://lucene.472066.n3.nabble.com/Unable-to-load-com-microsoft-sqlserver-jdbc-SQLServerDriver-tp4083529.html
Sent from the Solr - User mailing list archive at Nabble.com.

Mime
View raw message