title: An association from the table CountryList refers to an unmapped class
body: <p>I am getting the exception </p>
  
  <blockquote>
    <p>Initial SessionFactory creation failed.org.hibernate.MappingException: An association from the table CountryList refers to an unmapped class: com.abegaa.model.StateListPojo</p>
  </blockquote>
  
  <p>for the hibernate Mapping between for this two hbm file </p>
  
  <p>1st one CountryList and StateList</p>
  
  <pre><code>&lt;?xml version="1.0"?&gt;
  
  &lt;!DOCTYPE hibernate-mapping PUBLIC
  "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
  "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd"&gt;
  
  &lt;hibernate-mapping package="com.abegaa.model"&gt;
  
   &lt;class name="CountryListPojo" table="CountryList"&gt;
   &lt;id name="Id" column="Id"&gt;
   &lt;generator class="increment"&gt;&lt;/generator&gt;
    &lt;/id&gt;
  
   &lt;many-to-one name="Db_CountryId" column="Db_CountryId" class="StateListPojo"&gt;&lt;/many-to-one&gt;
  
    &lt;property name="Db_CountryName" column="Db_CountryName"&gt;&lt;/property&gt;
    &lt;/class&gt;
  &lt;/hibernate-mapping&gt;
  </code></pre>
  
  <p>and </p>
  
  <pre><code>&lt;?xml version="1.0"?&gt;
  &lt;!DOCTYPE hibernate-mapping PUBLIC
  "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
  "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd"&gt;
  &lt;hibernate-mapping package="com.abegaa.model"&gt;
    &lt;class name="StateListPojo" table="StateList"&gt;
  
   &lt;id name="Id" column="Id"&gt;
   &lt;generator class="increment"&gt;&lt;/generator&gt;&lt;/id&gt;
  
   &lt;set name="Db_CountryId"&gt;
      &lt;key column="Db_CountryId"&gt;&lt;/key&gt;
  &lt;one-to-many class="CountryListPojo"/&gt;
    &lt;/set&gt;
  
    &lt;property name="Db_StateId" column="Db_StateId"/&gt;
    &lt;property name="Db_StateName" column="Db_StateName"/&gt;
    &lt;/class&gt;
  &lt;/hibernate-mapping&gt;
  </code></pre>
  
  <p>and this is my classes.</p>
  
  <pre><code>public class CountryListPojo
  {
  
         private long Id;
  private String Db_CountryId;
  private String Db_CountryName;
      //get and set
  } 
  
   public class StateListPojo 
  {
  
  private String Id;
  private String Db_CountryId;
  private String Db_StateId,Db_StateName;
   //get and set
   }
  </code></pre>
  
  <p>I can't understand where i am doing wrong ?</p>