A dialect is a class that provides information about the specifics of a database and translators for the SQL dialect of the database.

Supported dialects

Hibernate ORM supports a wide range of dialects out of the box.

Usually, Hibernate supports at least the database version that is also still supported by the respective vendor. In many cases though, Hibernate supports even older versions of the databases, but the support for these versions is not guaranteed.

Below is a list of supported dialects and the minimum required version of the database.

Dialect Minimum Database Version

AzureSQLServerDialect

11.0

CockroachDialect

22.2

DB2Dialect

10.5

DB2iDialect

7.1

DB2zDialect

12.1

DerbyDialect

10.15.2

H2Dialect

2.1.214

HANADialect

1.0.120

HSQLDialect

2.6.1

MariaDBDialect

10.4

MySQLDialect

8.0

OracleDialect

19.0

PostgreSQLDialect

12.0

PostgresPlusDialect

12.0

SQLServerDialect

11.0

SpannerDialect

N/A

SybaseASEDialect

16.0

SybaseDialect

16.0

TiDBDialect

5.4

Third-party dialects

Third-parties publish additional dialects for Hibernate ORM, providing their own support for more databases, or extended support beyond what is built in Hibernate ORM.

These dialects are not directly supported by the Hibernate team:

  • The Hibernate ORM CI does not run any test against these dialects, the dialect’s authors have their own test suite.

  • The Hibernate team will not address issues reported against these dialect, but the dialect’s authors have their own issue tracker.

Third-party dialects may not be compatible with all versions of Hibernate ORM.

Check the dialect’s own documentation to know more about its compatibility constraints. The compatibility matrix on the Hibernate website may also be of help.

Below is a list of third-party dialects with links to relevant websites.

Dialect Website

MongoDB

Google Spanner

Community dialects

Community dialects are not included in org.hibernate.orm:hibernate-core and require an additional dependency to org.hibernate.orm:hibernate-community-dialects.

These dialects are not directly supported by the Hibernate team:

  • The Hibernate ORM CI does not run any test against these dialects.

  • The Hibernate team will not address issues reported against these dialect.

Instead, the dialects are maintained on a best-effort basis by vendors or individuals.

Below is a list of community dialects and the minimum required version of the database.

Dialect Minimum Database Version

AltibaseDialect

N/A

CUBRIDDialect

N/A

CacheDialect

N/A

CockroachLegacyDialect

N/A

DB2LegacyDialect

N/A

DB2iLegacyDialect

N/A

DB2zLegacyDialect

N/A

DerbyLegacyDialect

N/A

FirebirdDialect

N/A

H2LegacyDialect

N/A

HSQLLegacyDialect

N/A

InformixDialect

N/A

IngresDialect

N/A

MariaDBLegacyDialect

N/A

MaxDBDialect

N/A

MimerSQLDialect

N/A

MySQLLegacyDialect

N/A

OracleLegacyDialect

N/A

PostgreSQLLegacyDialect

N/A

PostgresPlusLegacyDialect

N/A

RDMSOS2200Dialect

N/A

SQLServerLegacyDialect

N/A

SQLiteDialect

N/A

SingleStoreDialect

8.0

SybaseASELegacyDialect

N/A

SybaseAnywhereDialect

16.0

SybaseLegacyDialect

N/A

TeradataDialect

N/A

TimesTenDialect

N/A

Community dialects were introduced in Hibernate ORM 6.0.

The hibernate-core artifact had many legacy dialects before 6.0 that were only tested and maintained on a best effort basis. More and more database vendors requested to integrate a dialect for their database and even provided a PR with a dialect, but the Hibernate team didn’t want to add new dialects for databases that might not have a wide adoption or any automated testing into the hibernate-core artifact. Even though the dialect was supposedly maintained by the vendor, the Hibernate team was burdened with reviewing questions, issues and PRs that relate to these dialects.

To give database vendors and the community a clear way forward, the Hibernate team decided to introduce a new artifact, called hibernate-community-dialects which is the new home for dialects that are maintained by vendors or individuals.

Moving forward, the hibernate-core artifact will only contain dialects that are supported and tested by the Hibernate team. All the legacy dialects were moved to the hibernate-community-dialects artifact to have a clear separation based on the quality of the dialect.

Requirements for moving from hibernate-community-dialects to hibernate-core

If a database vendor wants their database dialect to be included in the hibernate-core artifact, several requirements have to be fulfilled:

  • The vendor must provide access to a dedicated database server that can be used for testing

  • The vendor must provide contact details to at least one employee who is mainly responsible for the maintenance of the dialect

  • The responsible employee of the vendor must actively monitor and react to failures of the testsuite against the respective database

  • The responsible employee of the vendor must ensure the testsuite is configured correctly in order for it to succeed on the respective database

  • If the responsible employee of the vendor leaves the company, the vendor must provide contact details to a new responsible employee

In case the responsible employee is unreachable for a longer period or issues with the dialect are not attended to in a timely manner, the Hibernate team will move the dialect back to the hibernate-community-dialects artifact.

The requirements for the database server are:

  • JDK 17 installed

  • Git installed

  • Access to the database through non-confidential credentials

  • Access via SSH through confidential credentials

Get in touch with the Hibernate team on Zulip if you want to request the move of your dialect to hibernate-core.