< Prev
Next >

Hibernate - Entity object and Value Type Object

Today we are going to understand the concept of Value type object in Hibernate and how it is different from an Entity object. Entity object is an object of our plain old java class(POJO) Model/Business class, which needs to be persisted in a database using Hibernate, while Value Type object is an object of another class but it is stored as a part of Entity object within a database table.

Entity class v/s Value Type class

Let's suppose, we have two classes Employee_Details and Credentials, where Employee_Details contains the information about the identification number, first name and last name of each employee and Credentials class refers to the information such as skills, number of years of experience and awards received by each employee.

Let's put this example to work to have a better understanding of the concept.

Note :

Please Subscribe

Please subscribe to our social media channels for daily updates.

Decodejava Facebook Page  DecodeJava Twitter Page Decodejava Google+ Page



Please check our latest addition