title: Get the record by ID in Hibernate
body: <p>I am doing some CRUD operations. So I found how to create, update, delete and partial select statement. Why I said partial select means I have three entities called <code>Person</code>, <code>ContactInformation</code> and <code>Address</code>. Relationship between these three objects is <code>Address</code> is a foreign key in <code>ContactInformation</code> and the <code>ContactInformation</code> is the foreign key in <code>Person</code>. So now I know the Person ID and how can I get the record (Means I want <code>Person</code>, <code>ContactInformation</code> and <code>Address</code> Record) related to this Person ID. At present I am using </p>
  
  <pre><code>    Model model = (Model) this.getCurrentSession().get(
                  this.getPersistentClass(), argId);
  </code></pre>
  
  <p>Here Persistent class is <code>Person.class</code>. So with this I am able to get the <code>Person</code> record but I am not able to get the <code>ContactInformation</code> and <code>Address</code> records. See the below Image.</p>
  
  <p><img src="https://i.stack.imgur.com/iDVKO.jpg" alt="enter image description here"></p>