Tag: embeddable
-
How to represent a composite key in hibernate?
Consider the below class representing a Student. It has a primary key id , a class id and a name field. Say you want to combine the id and class id into a composite key. You want the same student id to be used against a different class id. We can achieve this in hibernate…