Hello,
I try to migrate a webapp actually Struts1.1 and Hibernate1.2.5 based and I'm a little confused.
I've an mapping of subclasses like that :
Code:
<class name="Demande" table="tbl_demandes">
<id name="key" column="id" type="long">
<generator class="sequence">
<param name="sequence">seq_tbl_demandes</param>
</generator>
<!--generator class="assigned"/-->
</id>
<discriminator column="class"/>
<property name="statut" type="string"/>
<subclass name="com.Purchase" discriminator-value="Purchase">
<property name="periodicity" type="string"/>
</subclass>
</class>
In a controller, I should do :
Code:
Demande demande = (Demande)session.load(Demande.class, new Long(1))
request.setAttribute("demande", demande);
"demande" is an instance of PurchaseThen in a jsp :
<bean:write name="demande" property="periodicity"/>
==> Exception
javax.servlet.ServletException: No getter method for property periodicity of bean demandeI can't understand why
Can you help me ?
Thanks
Franck
[/b]
Code: