Introduction to Jdbc With Postgresql, Mysql, and Oracle in Java
Below are the summary of connection settings for differenct jdbc provider: Database Connection Url Driver Class Hibernate Di...
https://www.czetsuyatech.com/2013/03/jdbc-provider-setting-in-java-for.html
Below are the summary of connection settings for differenct jdbc provider:
*Note in Oracle driver class and hibernate dialect are not required.
Database | Connection Url | Driver Class | Hibernate Dialect | Cache Provider Class |
PostgreSQL | jdbc:postgresql://[host]:[port]/[db] | org.postgresql.Driver | org.hibernate.dialect.PostgreSQLDialect | |
MySQL | jdbc:mysql://[host]:[port]/[db] | com.mysql.jdbc.Driver | org.hibernate.dialect.MySQLDialect | |
Oracle | jdbc:oracle:thin:@[host]:[port]:[db] | oracle.jdbc.OracleDriver | org.hibernate.dialect.OracleDialect | |
HSQL DB | jdbc:hsqldb:mem:core | org.hsqldb.jdbcDriver | org.hibernate.cache.NoCacheProvider / org.hibernate.cache.HashtableCacheProvider | |
Oracle XE | jdbc:oracle:thin:@localhost:1521:XE | oracle.jdbc.driver.OracleDriver | org.hibernate.cache.NoCacheProvider / org.hibernate.cache.HashtableCacheProvider |
*Note in Oracle driver class and hibernate dialect are not required.
1 comment
I think as long as you have connection to the database when you start your app, the dialect can be detected by hibernate.
Post a Comment