Hi everyone-
New to Hibernate and having a problem mapping an element. Here is the mapping file:
<hibernate-mapping>
<typedef class="org.acord.standards.pc_surety.acord1_12_0.xml.C25" name="C25"/>
<class name="org.acord.standards.pc_surety.acord1_12_0.xml.PCPOLICY" table="ZEUS_REP.POLICY_INQUIRY_MV">
<id name="PolicyNumber" column="POLICY_NO" type="C25">
<generator class="native"/>
</id>
<property name="CurrentTermAmt" column="POLICY_TERM" type="currency"/>
<property name="PolicyStatusCd" column="POLICY_STATUS" type="string"/>
<property name="ControllingStateProvCd" column="POLICY_STATE" type="string"/>
</class>
</hibernate-mapping>
Unfortunately the domain model did not use any simple Java types but instead created their own for every element. So although PolicyNumber is essentially just a String, it is of custom Java class C25.
This is the exception I get:
failed.org.hibernate.MappingException: Could not determine type for: org.acord.standards.pc_surety.acord1_12_0.xml.C25, for columns: [org.hibernate.mapping.Column(POLICY_NO)]
What simple piece am I missing?
Thanks,
-Allon
|