How to create primary key using hibernate?

Hi,

How to create primary key using hibernate?

Thanks,

View Answers

May 2, 2013 at 12:03 PM

Hi,

Every relational table has a "natural" primary key. However, it may be unrecognized and undefined. To create primary key using hibernate we need to specify the key generation techniques in hibernate?s XML mapping file.

Here is syntax for Primary key in hibernate

For more visit this link : http://www.roseindia.net/hibernate/

Thanks,









Related Tutorials/Questions & Answers:
Advertisements