JDBC Driver Maven dependency list

JDBC Driver Maven dependency list
Techiio-author
Written by Sagar RabidasFebruary 22, 2022
8 min read
Hibernate
1 VIEWS 0 LIKES 0 DISLIKES SHARE
0 LIKES 0 DISLIKES 1 VIEWS SHARE
Techiio-author
Sagar Rabidas

Software Developer

Let's start the discussion with JDBC Driver Maven dependency list

Introduction of JDBC Driver:-

A JDBC driver is a software component enabling a Java application to interact with a database. JDBC drivers are analogous to ODBC drivers, ADO.NET data providers, and OLE DB providers. To connect with individual databases, JDBC (the Java Database Connectivity API) requires drivers for each database.

Oracle:-

Since September 2019, the Oracle JDBC Driver is available on Maven Central.

For Java 11 and newer version, use the following Maven dependency:

<dependency>
    <groupId>com.oracle.database.jdbc</groupId>
    <artifactId>ojdbc10</artifactId>
    <version>${oracle.version}</version>
</dependency>

For Java 8, use the ojdbc8 artifact instead:

<dependency>
    <groupId>com.oracle.database.jdbc</groupId>
    <artifactId>ojdbc8</artifactId>
    <version>${oracle.version}</version>
</dependency>

For Java 6, use the ojdbc6 artifact instead:

<dependency>
    <groupId>com.oracle.database.jdbc</groupId>
    <artifactId>ojdbc6</artifactId>
    <version>${oracle.version}</version>
</dependency>

For more details about the proper version to use, check out the following Maven Central link.

MySQL:-

The MySQL Driver is available on Maven Central, so just add the following dependency to your pom.xml file:

<dependency>
    <groupId>mysql</groupId>
    <artifactId>mysql-connector-java</artifactId>
    <version>${mysql.version}</version>       
</dependency>

Use this Maven Central link to get the latest artifact version for the MySQL JDBC Driver.

PostgreSQL:-

The PostgreSQL Driver is available on Maven Central, so us the following dependency:

<dependency>
    <groupId>org.postgresql</groupId>
    <artifactId>postgresql</artifactId>
    <version>${postgresql.version}</version>
</dependency>

This Maven Central link will tell you which is the latest version of the PostgreSQL JDBC artifact.

SQL Server:-

While many years ago, the official Microsoft SQL Server JDBC Driver was in a bad shape, to the extent that the Java community created the jTDS open-source JDBC Driver, nowadays, the SQL Server JDBC Driver is open-source and available on both GitHub and Maven Central:

<dependency>
    <groupId>com.microsoft.sqlserver</groupId>
    <artifactId>mssql-jdbc</artifactId>
    <version>${mssql.version}</version>
</dependency>

To get the latest version of the SQL Server JDBC Driver, use this Maven Central query link.

Db2:-

You can get the Db2 JDBC Driver either from the IBM website and install it to your local Maven repository, or get it from Maven Central.

<dependency>
    <groupId>com.ibm.db2</groupId>
    <artifactId>jcc</artifactId>
    <version>${db2.version}</version>               
</dependency>

To get the latest version of the Db2 JDBC Driver, use this Maven Central query link.

MariaDB:-

You can get the MariaDB JDBC Driver from Maven Central using the following dependency:

<dependency>
    <groupId>org.mariadb.jdbc</groupId>
    <artifactId>mariadb-java-client</artifactId>
    <version>${mariadb.version}</version>               
</dependency>

Use this Maven Central link to get the latest artifact version for the MariaDB JDBC Driver.

SAP Hana:-

To get the SAP HANA JDBC driver from Maven central using the following dependency.

Afterward, use the following Maven dependency:

<dependency>
    <groupId>com.sap.cloud.db.jdbc</groupId>
    <artifactId>ngdbc</artifactId>
    <version>${hana.version}</version>               
</dependency>

Informix:-

Since 2017, the Informix JDBC Driver is available on Maven Central. Use the following Maven dependency to get it:

<dependency>
    <groupId>com.ibm.informix</groupId>
    <artifactId>jdbc</artifactId>
    <version>${informix.version}</version>
</dependency>

This Maven Central query link will provide you with the latest version of the Informix JDBC Driver.

Firebird:-

Jaybird is the JDBC Driver for Firebird, and you can get it from Maven Central like this:

<dependency>
    <groupId>org.firebirdsql.jdbc</groupId>
    <artifactId>jaybird</artifactId>
    <version>${jaybird.version}</version>
</dependency>

To get the latest version of the Firebird JDBC Driver, use this Maven Central query link.

HSQLDB:-

You can get the HyperSQL JDBC Driver using the following Maven dependency:

<dependency>
    <groupId>org.hsqldb</groupId>
    <artifactId>hsqldb</artifactId>
    <version>${hsqldb.version}</version>
    <scope>test</scope>
</dependency>

Use this Maven Central link to get the latest artifact version for the HSQLDB JDBC Driver.

H2:-

The H2 database JDBC Driver is available on Maven Central, so you can use the following Maven dependency:

<dependency>
    <groupId>com.h2database</groupId>
    <artifactId>h2</artifactId>
    <version>${h2.version}</version>
    <scope>test</scope>
</dependency>

This Maven Central link will tell you which is the latest version of the H2 JDBC artifact.

Derby:-

Use the following Maven dependency to get the Apache Derby JDBC Driver from Maven Central:

<dependency>
    <groupId>org.apache.derby</groupId>
    <artifactId>derby</artifactId>
    <version>${derby.version}</version>
    <scope>test</scope>
</dependency>

Hibernate
JDBC Driver
Jdbc
Java Database
1 VIEWS 0 LIKES 0 DISLIKES SHARE
0 LIKES 0 DISLIKES 1 VIEWS SHARE
Was this blog helpful?
techiio-price-plantechiio-price-plantechiio-price-plantechiio-price-plantechiio-price-plan
You must be Logged in to comment
Code Block
Techiio-author
Sagar Rabidas
Software Developer
Techiio-followerTechiio-followerTechiio-followerTechiio-followerTechiio-follower
+8 more
300 Blog Posts
14 Discussion Threads
Trending Technologies
15
Software40
DevOps46
Frontend Development24
Backend Development20
Server Administration17
Linux Administration26
Data Center24
Sentry24
Terraform23
Ansible83
Docker70
Penetration Testing16
Kubernetes21
NGINX20
JenkinsX17
Techiio-logo

Techiio is on the journey to build an ocean of technical knowledge, scouring the emerging stars in process and proffering them to the corporate world.

Follow us on:

Subscribe to get latest updates

You can unsubscribe anytime from getting updates from us
Developed and maintained by Wikiance
Developed and maintained by Wikiance