Upravit

Sdílet prostřednictvím


Deploying the JDBC driver

Download JDBC driver

When you deploy an application that depends on the Microsoft JDBC Driver for SQL Server, you must redistribute the JDBC driver together with your application. Unlike Windows Data Access Components (Windows DAC), which is a component of the Windows operating system, the JDBC driver is considered to be a component of SQL Server.

There are two approaches to deploying the JDBC driver with your application. One is to include the JDBC driver files as part of your own custom installation package. The second approach involves using the JDBC installation package provided by Microsoft, which you can download from the Microsoft JDBC Driver for SQL Server download page.

The following sections discuss how to use the JDBC installation package on Windows and UNIX operating systems.

Note

For information about deploying Java applications in general, see the Java website.

Deploying the JDBC driver on Windows systems

When you deploy the JDBC driver on Windows operating systems, you must unpack the zipped installation package, which is typically named sqljdbc_<version>_<language>.zip.

Deploying the driver on UNIX systems

When you deploy the JDBC driver on UNIX operating systems, you must use the gzip file version of the installation package, which is typically named sqljdbc_<version>_<language>.tar.gz.

Before you install the JDBC driver, make sure that both the gzip and tar utilities are installed on the user's system, and that the folders that contain the executables for both utilities are added to the PATH environment variable.

To unpack the zipped tar file, navigate to the directory where you want the driver unpacked and type the following command:

gzip -d sqljdbc_<version>_<language>.tar.gz

To unpack the tar file, move it to the directory where you want the driver installed and type the following command:

tar -xf sqljdbc_<version>_<language>.tar

Legalities of driver redistribution

All versions of the JDBC Driver versions 6.0 and up are redistributable. Review the Distributable Code clause in the license agreements.

The JDBC Driver versions 4.x are old and obsolete. Support for 4.x expired before 2018.

See also

Overview of the JDBC driver