EJB Spec
2.1.4 The application must not change the value of the primary key. The behavior is undefined if this
occurs.[5]
So, if the entity uses the following @Id(generate=GeneratorType.NONE), I guess the above req does not apply?
What's the behavior of Hibernate Annotation?
EJB Spec 9.1.8 Id Annotation
public enum GeneratorType { TABLE, SEQUENCE, IDENTITY, AUTO, NONE };
Specifying NONE indicates that no primary
key generation by the persistence provider should occur, and that the application will be responsible
for assigning the primary key.
|