Mohan's HibernateBook
Hibernate Interview Questions
ContactUs
Please send your Questions & Answers or Feedback to "mohan@javabook.org"
How do you define sequence generated primary key in hibernate?
Using <generator> tag.
Example:-
<id column="USER_ID" name="id" type="java.lang.Long">
<generator class="sequence">
<param name="table">SEQUENCE_NAME</param>
<generator>
</id>
Newer Post
Older Post
Home