Sets the identity strategy of the enclosing element to use sequences of the underlying relational database system.
To define a named sequence for later use:
To define a sequence for use in a PersistentField:
To re-use a sequence that has already been defined:
client-side-name: A unique name of the sequence. This is used for sequence references, to identify the sequence to be reused. If client-side-name is not specified, Genome generates a name automatically from the type and the member name.
server-side-name: The name of the sequence to be generated in the underlying relational database system. If server-side-name is not specified, the client-side-name is used to refer to the sequence in the database.
client-side-name-reference: A reference to a sequence defined elsewhere in the mapping files. The value has to be a client-side-name defined for an other sequence.
· The mapped property must be of a numeric type.
· This mapping feature can only be applied to read only properties (i.e. can only have a getter).
Define and use an unnamed sequence:
Define and use an unnamed sequence, specifying the sequence name to be used in the database:
Define a named sequence and reuse it for different classes:
Database Platforms:Oracle 9i Release 2, Oracle 10g Release 2
<PersistentField> Element | Object Identity Generation Strategies
|<AutoIncrement> Element||<NativeIdGenerator> Element|