getGeneratedKeys.
In this respect it works much like ANSI-SQL IDENTITY generation.
This generator only known to work with newer Oracle drivers compiled for JDK 1.4 (JDBC3).
Note
Due to a bug in Oracle drivers, sql comments on these insert statements are completely disabled.
| Modifier and Type | Class and Description |
|---|---|
| public static class | |
| public static class |
| Modifier and Type | Field and Description |
|---|---|
| private static final Logger |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | configure(Type type, Properties
param values, keyed by parameter name params, Dialect dialect)Overrides org. Implements org. |
| public Serializable | generate(SessionImplementor s, Object
the entity or toplevel collection for which the id is being generated obj)Overrides org. Implements org. |
| public InsertGeneratedIdentifierDelegate | getInsertGeneratedIdentifierDelegate(PostInsertIdentityPersister persister, Dialect dialect, boolean isGetGeneratedKeysEnabled)
Implements org. |
| log | back to summary |
|---|---|
| private static final Logger log | |
| SequenceIdentityGenerator | back to summary |
|---|---|
| public SequenceIdentityGenerator() | |
| configure | back to summary |
|---|---|
| public void configure(Type type, Properties params, Dialect dialect) throws MappingException Overrides org. Implements org. Doc from org. Configure this instance, given the value of parameters specified by the user as <param> elements. This method is called just once, following instantiation.
| |
| generate | back to summary |
|---|---|
| public Serializable generate(SessionImplementor s, Object obj) Overrides org. Implements org. Doc from org. Generate a new identifier.
| |
| getInsertGeneratedIdentifierDelegate | back to summary |
|---|---|
| public InsertGeneratedIdentifierDelegate getInsertGeneratedIdentifierDelegate(PostInsertIdentityPersister persister, Dialect dialect, boolean isGetGeneratedKeysEnabled) throws HibernateException Implements org. | |
| Modifier and Type | Field and Description |
|---|---|
| private final Dialect | |
| private final String[] | |
| private final String |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| protected Serializable | executeAndExtract(PreparedStatement insert)
Implements abstract org. |
| protected PreparedStatement | prepare(String insertSQL, SessionImplementor session)
Implements abstract org. |
| public IdentifierGeneratingInsert | prepareIdentifierGeneratingInsert()
Implements org. org. specific to the delegate's mode
of handling generated key values.
|
| dialect | back to summary |
|---|---|
| private final Dialect dialect | |
| keyColumns | back to summary |
|---|---|
| private final String[] keyColumns | |
| sequenceNextValFragment | back to summary |
|---|---|
| private final String sequenceNextValFragment | |
| Delegate | back to summary |
|---|---|
| public Delegate(PostInsertIdentityPersister persister, Dialect dialect, String sequenceName) | |
| executeAndExtract | back to summary |
|---|---|
| protected Serializable executeAndExtract(PreparedStatement insert) throws SQLException Implements abstract org.
| |
| prepare | back to summary |
|---|---|
| protected PreparedStatement prepare(String insertSQL, SessionImplementor session) throws SQLException Implements abstract org. | |
| prepareIdentifierGeneratingInsert | back to summary |
|---|---|
| public IdentifierGeneratingInsert prepareIdentifierGeneratingInsert() Implements org. Doc from org. Build a
| |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public Insert |
| NoCommentsInsert | back to summary |
|---|---|
| public NoCommentsInsert(Dialect dialect) | |
| setComment | back to summary |
|---|---|
| public Insert setComment(String comment) Overrides org. | |