December 09, 2014

Manually Adding Dependency in Spring MicroSoft SQLServer JDBC Driver

Hi Friends,

Today, I’ve spent more than 40 minutes in understanding the process and setting up the SQLServer JDBC Driver in Spring manually


Maven (Download from and add the maven path to environment variables)


  1. Download the latest Microsoft JDBC driver for SQL Server from the following official link
  2. I’ve selected sqljdbc jar version 4.0
  3. Navigate to the extracted folder where .jar files available in command prompt
  4. Execute the following command
  5. cmd> mvn install:install-file -DartifactId=sqljdbc -Dversion=4.0 -Dpackaging=jar -Dfile="sqljdbc4.jar"
  6. Now you should be able to see the downloading and moving the corresponding .jar and .pom files. Then a message “BUILD SUCCESS” will appear in command prompt.
  7. Add the following dependency to your pom.xml
<!-- Database -->

    Now you run the project and enjoy the usage of SQLServer Database with Spring.

    Please send your feedback and comments to

    Blogger Labels: Dependency,MicroSoft,SQLServer,JDBC,Driver,Friends,Procedure,Download,Server,version,Navigate,folder,Execute,DgroupId,DartifactId,Dversion,Dfile,message,BUILD,Database,usage,feedback,sqljdbc,groupId,artifactId
    Post a Comment

    Featured Post

    Java Introdcution

    Please send your review and feedback to