I'm migrating from Hibernate 2 to Hibernate 3.25. When I run the query below I got this error:
Quote:
0000001a BasicProperty E org.hibernate.property.BasicPropertyAccessor$BasicGetter get IllegalArgumentException in class: DomainObject, getter method of property: shortName
My teste class extends DomainObject. I don't map all properties of DomainObject on hbm file because I don't need it.
shortName is a String
Query
Code:
<query name="findByIdAndDate">
<![CDATA[select ts.curveValue
from teste ts
where ts.date = :date
and ts.swap.id = :id
and ts.currency = :currency]]>
</query>
Mapping
Code:
<class name="teste" table="teste">
<id name="id" column="TESTE_ID" type="java.lang.Long">
<generator class="sequence">
<param name="sequence">TESTE_SEQ</param>
</generator>
</id>
<property name="date" column="DATE" type="java.util.Date" />
<property name="curveValue" column="CURVE_VALUE" type="java.math.BigDecimal"/>
<many-to-one name="swap" class="Swap" column="SWAP_ID" lazy="false"/>
<many-to-one name="currency" column="CURRENCY_CODE" class="Currency" lazy="false"/>
</class>