Я хочу использовать ту же коллекцию (Array) в своем Mapper.xml, поэтому я попытался использовать такое же предложение foreach, как это.
... B.EVT_ID IN
<foreach collection="evtID" item="evtID" index="index" open="(" close=")" separator=",">
#{evtID}
</foreach>
...
...
...
... D.EVT_ID IN
<foreach collection="evtID" item="evtID" index="index" open="(" close=")" separator=",">
#{evtID}
</foreach>
AND ...
the first foreach clause works perfectly, but the second, make an Error like this :
"nested exception is org.apache.ibatis.builder.BuilderException : Error evaluating expression 'evtID'. Return value (evtID's lastval) was not iterable."
I Think index, used in same collection based foreach clause wasn't reset when it finished.
so, I wonder how can i reset that index?