hibernate.hbm2ddl.auto (e.g. none (default value), create-only , drop , create , create-drop , validate , and update )

Setting to perform SchemaManagementTool actions automatically as part of the SessionFactory lifecycle. Valid options are defined by the externalHbm2ddlName value of the Action enum: none No action will be performed. create-only Database creation will be generated. drop Database dropping will be generated. create Database dropping will be generated followed by database creation. create-drop Drop the schema and recreate it on SessionFactory startup. Additionally, drop the schema on SessionFactory shutdown. validate Validate the database schema update Update the database schema

javax.persistence.schema-generation.database.action (e.g. none (default value), create-only , drop , create , create-drop , validate , and update )

Setting to perform SchemaManagementTool actions automatically as part of the SessionFactory lifecycle. Valid options are defined by the externalJpaName value of the Action enum: none No action will be performed. create Database creation will be generated. drop Database dropping will be generated. drop-and-create Database dropping will be generated followed by database creation.

javax.persistence.schema-generation.scripts.action (e.g. none (default value), create-only , drop , create , create-drop , validate , and update )

Setting to perform SchemaManagementTool actions writing the commands into a DDL script file. Valid options are defined by the externalJpaName value of the Action enum: none No action will be performed. create Database creation will be generated. drop Database dropping will be generated. drop-and-create Database dropping will be generated followed by database creation.

javax.persistence.schema-generation-connection

Allows passing a specific java.sql.Connection instance to be used by SchemaManagementTool

javax.persistence.database-product-name

Specifies the name of the database provider in cases where a Connection to the underlying database is not available (aka, mainly in generating scripts). In such cases, a value for this setting must be specified. The value of this setting is expected to match the value returned by java.sql.DatabaseMetaData#getDatabaseProductName() for the target database. Additionally, specifying javax.persistence.database-major-version and/or javax.persistence.database-minor-version may be required to understand exactly how to generate the required schema commands.

javax.persistence.database-major-version

Specifies the major version of the underlying database, as would be returned by java.sql.DatabaseMetaData#getDatabaseMajorVersion for the target database. This value is used to help more precisely determine how to perform schema generation tasks for the underlying database in cases where javax.persistence.database-product-name does not provide enough distinction.

javax.persistence.database-minor-version

Specifies the minor version of the underlying database, as would be returned by java.sql.DatabaseMetaData#getDatabaseMinorVersion for the target database. This value is used to help more precisely determine how to perform schema generation tasks for the underlying database in cases where javax.persistence.database-product-name and javax.persistence.database-major-version does not provide enough distinction.

javax.persistence.schema-generation.create-source

Specifies whether schema generation commands for schema creation are to be determine based on object/relational mapping metadata, DDL scripts, or a combination of the two. See SourceType for valid set of values. If no value is specified, a default is assumed as follows: if source scripts are specified (per javax.persistence.schema-generation.create-script-source ), then scripts is assumed

otherwise, metadata is assumed

javax.persistence.schema-generation.drop-source

Specifies whether schema generation commands for schema dropping are to be determine based on object/relational mapping metadata, DDL scripts, or a combination of the two. See SourceType for valid set of values. If no value is specified, a default is assumed as follows: if source scripts are specified (per javax.persistence.schema-generation.create-script-source ), then scripts is assumed

otherwise, metadata is assumed

javax.persistence.schema-generation.create-script-source

Specifies the create script file as either a java.io.Reader configured for reading of the DDL script file or a string designating a file java.net.URL for the DDL script. Hibernate historically also accepted hibernate.hbm2ddl.import_files for a similar purpose, but javax.persistence.schema-generation.create-script-source should be preferred over hibernate.hbm2ddl.import_files .

javax.persistence.schema-generation.drop-script-source

Specifies the drop script file as either a java.io.Reader configured for reading of the DDL script file or a string designating a file java.net.URL for the DDL script.

javax.persistence.schema-generation.scripts.create-target

For cases where the javax.persistence.schema-generation.scripts.action value indicates that schema creation commands should be written to DDL script file, javax.persistence.schema-generation.scripts.create-target specifies either a java.io.Writer configured for output of the DDL script or a string specifying the file URL for the DDL script.

javax.persistence.schema-generation.scripts.drop-target

For cases where the javax.persistence.schema-generation.scripts.action value indicates that schema dropping commands should be written to DDL script file, javax.persistence.schema-generation.scripts.drop-target specifies either a java.io.Writer configured for output of the DDL script or a string specifying the file URL for the DDL script.

javax.persistence.hibernate.hbm2ddl.import_files (e.g. import.sql (default value))

Comma-separated names of the optional files containing SQL DML statements executed during the SessionFactory creation. File order matters, the statements of a give file are executed before the statements of the following one. These statements are only executed if the schema is created, meaning that hibernate.hbm2ddl.auto is set to create , create-drop , or update . javax.persistence.schema-generation.create-script-source / javax.persistence.schema-generation.drop-script-source should be preferred.

javax.persistence.sql-load-script-source

JPA variant of hibernate.hbm2ddl.import_files . Specifies a java.io.Reader configured for reading of the SQL load script or a string designating the file java.net.URL for the SQL load script. A "SQL load script" is a script that performs some database initialization (INSERT, etc).

hibernate.hbm2ddl.import_files_sql_extractor

Reference to the ImportSqlCommandExtractor implementation class to use for parsing source/import files as defined by javax.persistence.schema-generation.create-script-source , javax.persistence.schema-generation.drop-script-source or hibernate.hbm2ddl.import_files . Reference may refer to an instance, a Class implementing ImportSqlCommandExtractor of the fully-qualified name of the ImportSqlCommandExtractor implementation. If the fully-qualified name is given, the implementation must provide a no-arg constructor. The default value is SingleLineSqlCommandExtractor .

hibernate.hbm2dll.create_namespaces (e.g. true or false (default value))

Specifies whether to automatically create also the database schema/catalog.

javax.persistence.create-database-schemas (e.g. true or false (default value))

The JPA variant of hibernate.hbm2dll.create_namespaces . Specifies whether the persistence provider is to create the database schema(s) in addition to creating database objects (tables, sequences, constraints, etc). The value of this boolean property should be set to true if the persistence provider is to create schemas in the database or to generate DDL that contains "CREATE SCHEMA" commands. If this property is not supplied (or is explicitly false ), the provider should not attempt to create database schemas.

hibernate.hbm2ddl.schema_filter_provider

Used to specify the SchemaFilterProvider to be used by create , drop , migrate , and validate operations on the database schema. SchemaFilterProvider provides filters that can be used to limit the scope of these operations to specific namespaces, tables and sequences. All objects are included by default.

hibernate.hbm2ddl.jdbc_metadata_extraction_strategy (e.g. grouped (default value) or individually )

Setting to choose the strategy used to access the JDBC Metadata. Valid options are defined by the strategy value of the JdbcMetadaAccessStrategy enum: grouped SchemaMigrator and SchemaValidator execute a single java.sql.DatabaseMetaData#getTables(String, String, String, String[]) call to retrieve all the database table in order to determine if all the javax.persistence.Entity have a corresponding mapped database tables.This strategy may require hibernate.default_schema and/or hibernate.default_catalog to be provided. individually SchemaMigrator and SchemaValidator execute one java.sql.DatabaseMetaData#getTables(String, String, String, String[]) call for each javax.persistence.Entity in order to determine if a corresponding database table exists.

hibernate.hbm2ddl.delimiter (e.g. ; )

Identifies the delimiter to use to separate schema management statements in script outputs.

hibernate.schema_management_tool (e.g. A schema name)

Used to specify the SchemaManagementTool to use for performing schema management. The default is to use HibernateSchemaManagementTool

hibernate.synonyms (e.g. true or false (default value))

If enabled, allows schema update and validation to support synonyms. Due to the possibility that this would return duplicate tables (especially in Oracle), this is disabled by default.

hibernate.hbm2dll.extra_physical_table_types (e.g. BASE TABLE )

Identifies a comma-separated list of values to specify extra table types, other than the default TABLE value, to recognize as defining a physical table by schema update, creation and validation.

hibernate.schema_update.unique_constraint_strategy (e.g. DROP_RECREATE_QUIETLY , RECREATE_QUIETLY , SKIP )

Unique columns and unique keys both use unique constraints in most dialects. SchemaUpdate needs to create these constraints, but DBs support for finding existing constraints is extremely inconsistent. Further, non-explicitly-named unique constraints use randomly generated characters. Therefore, the UniqueConstraintSchemaUpdateStrategy offers the following options: DROP_RECREATE_QUIETLY Default option. Attempt to drop, then (re-)create each unique constraint. Ignore any exceptions being thrown. RECREATE_QUIETLY Attempts to (re-)create unique constraints, ignoring exceptions thrown if the constraint already existed SKIP Does not attempt to create unique constraints on a schema update.

hibernate.hbm2ddl.charset_name (e.g. Charset.defaultCharset() )

Defines the charset (encoding) used for all input/output schema generation resources. By default, Hibernate uses the default charset given by Charset.defaultCharset() . This configuration property allows you to override the default JVM setting so that you can specify which encoding is used when reading and writing schema generation resources (e.g. File, URL).

hibernate.hbm2ddl.halt_on_error (e.g. true or false (default value))