开发者

Which jar to use for connecting to MS SQL server

开发者 https://www.devze.com 2022-12-23 05:10 出处:网络
Can some one please guide me to understand which jar file i need to include in my applic开发者_如何学运维ation to be able to set up a jdbc connection with ms sql server.

Can some one please guide me to understand which jar file i need to include in my applic开发者_如何学运维ation to be able to set up a jdbc connection with ms sql server.

thanks in advance.


sqljdbc.jar and sqljdbc4.jar class library files to be used depending on your preferred Java Runtime Environment (JRE) settings. For more information about which JAR file to choose, see System Requirements for the JDBC Driver.

Downloads links and more information can be found here.


You can use jtds jar, you will also need to add the dll/so to you java library path.

EDIT: More recent release


The Microsoft SQL Server JDBC Driver version 2.0 provides sqljdbc.jar and sqljdbc4.jar class library files to be used depending on your preferred Java Runtime Environment (JRE) settings.

sqljdbc4.jar class library requires a Java Runtime Environment (JRE) of version 6.0 or later.


Microsoft started publishing their Driver JARs to the central Maven repo in 2017. See Maven Search for the available versions.

<dependency>
    <groupId>com.microsoft.sqlserver</groupId>
    <artifactId>mssql-jdbc</artifactId>
    <version>7.0.0.jre10</version>
</dependency>


http://www.microsoft.com/downloads/details.aspx?FamilyID=99B21B65-E98F-4A61-B811-19912601FDC9&displaylang=en

MS JDBC Driver. Has documentation.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号