You need to tell the iterate-tag which property to iterate:

<iterate property="accountIdList" open="ACCOUNTS.ID IN (" close=")" 
conjunction=",">
        #accountIdList[]#
</iterate>

Niels
________________________________________
From: Amad Fida [mailto:[EMAIL PROTECTED] 
Sent: woensdag 8 maart 2006 12:35
To: [email protected]
Subject: HashMap's List entry for <iterate>

I have a following select statement, 

<select id="getAccounts">
    select * from accounts 
            <dynamic prepend="WHERE">
                <iterate open="ACCOUNTS.ID IN (" close=")" conjunction=",">
                    #accountIdList[]#
                </iterate>
            </dynamic>
</select>

My parameter class is HashMap as i createa map like
Map params = new HashMap();
params.put("accountIdList", accountIds);

My assumption is that iBatis will lookup the accountIdList in the map and the 
returned value, which is a list w ill be used in <dynamic>. But I am gettng 
this error, 

--- Cause: com.ibatis.sqlmap.client.SqlMapException: ParameterObject or 
property was not a Collection, Array or Iterator.

I can't figure out what I am doing wrong. Any ideas?

Amad
________________________________________
Yahoo! Mail
Bring photos to life! New PhotoMail makes sharing a breeze. 

Reply via email to