Top Description Fields Constructors Methods
org.hibernate.dialect.temptable

public final Enum TemporaryTableKind

extends Enum<TemporaryTableKind>
Class Inheritance
Imports
org.hibernate.dialect.Dialect

Classifies the kinds of temporary table implementations.
Since
6.0

Field Summary

Modifier and TypeField and Description
public static final TemporaryTableKind
GLOBAL

Modeled as what the SQL standard calls a global temporary table, which is a table that is defined once per schema, but its data is scoped to a transaction where data is usually deleted automatically on transaction commit, though it is possible to control whether Hibernate should delete data or not through Dialect#getTemporaryTableAfterUseAction().

public static final TemporaryTableKind
LOCAL

Modeled as what the SQL standard calls a local temporary table, which is a table that is defined per connection.

public static final TemporaryTableKind
PERSISTENT

Modeled as a regular table with a special TemporaryTableSessionUidColumn, which is explicitly deleted from at the end of a transaction.

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static TemporaryTableKind
public static TemporaryTableKind[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

GLOBALback to summary
public static final TemporaryTableKind GLOBAL

Modeled as what the SQL standard calls a global temporary table, which is a table that is defined once per schema, but its data is scoped to a transaction where data is usually deleted automatically on transaction commit, though it is possible to control whether Hibernate should delete data or not through Dialect#getTemporaryTableAfterUseAction().

The table is created once on application startup, unless hibernate.query.mutation_strategy.global_temporary.create_tables is disabled and dropped on application startup unless hibernate.query.mutation_strategy.global_temporary.create_tables or hibernate.query.mutation_strategy.global_temporary.drop_tables are disabled.

LOCALback to summary
public static final TemporaryTableKind LOCAL

Modeled as what the SQL standard calls a local temporary table, which is a table that is defined per connection.

Usually, the table is created when needed in a transaction and databases usually drop it on transaction commit, though it is possible to control if Hibernate should drop it explicitly through Dialect#getTemporaryTableAfterUseAction() and hibernate.query.mutation_strategy.local_temporary.drop_tables.

PERSISTENTback to summary
public static final TemporaryTableKind PERSISTENT

Modeled as a regular table with a special TemporaryTableSessionUidColumn, which is explicitly deleted from at the end of a transaction.

The table is created once on application startup, unless hibernate.query.mutation_strategy.persistent.create_tables is disabled and dropped on application startup unless hibernate.query.mutation_strategy.persistent.create_tables or hibernate.query.mutation_strategy.persistent.drop_tables are disabled.

Constructor Detail

TemporaryTableKindback to summary
private TemporaryTableKind()

Method Detail

valueOfback to summary
public static TemporaryTableKind valueOf(String name)
valuesback to summary
public static TemporaryTableKind[] values()