Gareth,
Indeed - it works the way you described it.
Thanks for the help!
Yannick
Gareth Moorst wrote:
I think this is because of a different issue - when dealing with List
properties, I believe iBatis creates the list, sets it into the parent
class, then adds objects to the lists, so if you are doing any copying
of lists in the setAcc(List accs) method, then you will be copying an
empty list.
Hope this helps,
Gareth Moorst
*/Yannick Le Teigner <[EMAIL PROTECTED]>/* wrote:
Tony,
Indeed - looks like a bug.
What is even more troubling is that I have another similar
ResultMap that is working ok:
<resultMap id="subMarketMap" class="java.util.LinkedHashMap" >
<result property="id" column="s_id" />
<result property="siret" column="siret" />
<result property="name" column="s_name" />
<result property="percentage" column="s_percentage" />
</resultMap>
<resultMap id="marketMap"
class="com.montecristo.company.Market" groupBy="id">
<result property="id" column="id" />
<result property="name" column="name" />
<result property="location" column="location" />
<result property="volume" column="volume" />
<result property="value" column="value" />
<result property="leader" column="leader" />
<result property="growth" column="growth" />
<result property="percentage" column="percentage" />
<result property="growthComment" column="growth_comment" />
<result property="marketTypeId" column="market_type_id" />
<result property="customerProfileId"
column="customer_profile_id" />
<result property="subMarket"
resultMap="Orders.subMarketMap" />
</resultMap>
<select id="getMarket" parameterClass="java.lang.String"
resultMap="marketMap">
SELECT market.siret, market.id, market.name, location,volume,
value,leader, market.percentage, growth,growth_comment,
market_type_id, customer_profile_id, submarket.id as s_id,
submarket.name as s_name, submarket.percentage as s_percentage
FROM market LEFT JOIN submarket ON
market.siret=submarket.siret WHERE market.siret=#value:varchar#
</select>
Thanks,
Yannick
[EMAIL PROTECTED] wrote:
Yannick,
I'm having similar problem. please see my previous post,
"groupBy issue".
thanks,
Tony
------------------------------------------------------------------------
To help you stay safe and secure online, we've developed the all new
*Yahoo! Security Centre*
<http://us.rd.yahoo.com/mail/uk/taglines/default/security_centre/*http://uk.security.yahoo.com/>.