Joined: Mon Feb 09, 2009 10:54 am Posts: 1
|
Hi,
I've got a slight N+1 issue with an object that is retrieved using HQL. The object in question (FinancialTransaction) has got an <any> mapping (see below) Is it possible to eager initialize objects a that are mapped using the 'any' property?
E.g:
If I had a mapping such as this one could I eager load these obejcts as part of an HQL query using 'left join fetch' or similar?:
<any name="payable" meta-type="string" id-type="Int32" cascade="none" access="field">
<meta-value value="MP" class="MainPolicy"/>
<meta-value value="PI" class="Policy"/>
<meta-value value="AP" class="AdditionalPremiumPolicyInfo"/>
<meta-value value="PF" class="PolicyProviderFee"/>
<column name="PayableType"/>
<column name="PayableId"/>
</any>
If not are there any workarounds I could try?
The HQL query I am using is a basic select
Many thanks
|
|