Class ANSISequenceSupport
java.lang.Object
org.hibernate.dialect.sequence.spi.ANSISequenceSupport
- All Implemented Interfaces:
SequenceSupport
- Direct Known Subclasses:
DB2SequenceSupport
Standard family base for databases using the ANSI next value for
expression and ordinary create/drop sequence grammar.
Extend this class only when the database retains the ANSI next-value
expression. Override the non-final previous-value or DDL methods for the
database-specific differences and delegate unchanged behavior to super.
- Since:
- 8.0
-
Constructor Summary
ConstructorsConstructorDescriptionCreate an ANSI sequence-support strategy or provider subclass. -
Method Summary
Modifier and TypeMethodDescriptionfinal StringgetSelectSequenceNextValString(String sequenceName) Render the expression which obtains the next value inside another SQL statement.getSelectSequencePreviousValString(String sequenceName) Render the expression which obtains the previous value inside another SQL statement.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface SequenceSupport
getCreateSequenceString, getCreateSequenceString, getCreateSequenceStrings, getCreateSequenceStrings, getDropSequenceString, getDropSequenceStrings, getFromDual, getRestartSequenceString, getSequenceNextValString, getSequenceNextValString, getSequencePreviousValString, sometimesNeedsStartingValue, startingValue, supportsPooledSequences, supportsSequences
-
Constructor Details
-
ANSISequenceSupport
-
-
Method Details
-
getSelectSequenceNextValString
Description copied from interface:SequenceSupportRender the expression which obtains the next value inside another SQL statement. Do not include a surroundingselectstatement.- Specified by:
getSelectSequenceNextValStringin interfaceSequenceSupport- Parameters:
sequenceName- the qualified sequence name- Returns:
- the next-value expression
-
getSelectSequencePreviousValString
Description copied from interface:SequenceSupportRender the expression which obtains the previous value inside another SQL statement. Override this method only when the database exposes such an expression.- Specified by:
getSelectSequencePreviousValStringin interfaceSequenceSupport- Parameters:
sequenceName- the qualified sequence name- Returns:
- the previous-value expression
- Throws:
MappingException- when the operation is unsupported
-