Finding a solution becomes easy once you know how the classpath concept works in Java, a must-know for any Java developer. Similarly, in Java, web application JDBC drivers are required to be present in the WEB-INF/lib directory or if you are running on Tomcat then tomcat/lib directory as well. BTW, in most of the cases ": .SQLServerDriver" comes because of classpath intricacies.įor example, if your Java program is using -cp or -classpath option but you added the JAR into the CLASSPATH environment variable or vice-versa. Depending upon your situation, a solution could be as simple as downloading any of sqljdbc.jar, sqljdbc4.jar, or sqljdbc41.jar, based upon the Java version you are using and adding them into CLASSPATH as set CLASSPATH = %CLASSPATH% (path to Microsoft JDBC driver) in Windows. This error comes when you try to connect to the Microsoft SQL Server database from the Java program but the required JDBC driver is not available in Classpath or driver is available in CLASSPATH but the class loader is not able to find it due to classpath intricacies.
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |