title: MyBatis - Iterate over list which is value of HashMap in nested foreach loops
body: <pre><code>SELECT *
  FROM mytable
  &lt;foreach item="item" index="index" collection="myhashmap.entrySet()" open=" WHERE (" separator=" OR ("&gt; table.attribute= #{item.key} 
      &lt;foreach item="item2" index="index" collection="#{item.value}" separator=" ," open=" AND table.attribute IN (" close="))"&gt;
         #{item2.value} 
           &lt;/foreach&gt; 
   &lt;/foreach&gt;     
  </code></pre>
  
  <p>The Iteration over the hashmap works, but the list (which is in item.value) doesn't work.</p>
  
  <pre><code>Map&lt;Integer, List&lt;Integer&gt;&gt; myhashmap = new HashMap&lt;Integer, List&lt;Integer&gt;&gt;();
  </code></pre>
  
  <p>{item.value.iterator()} doesn't work too.</p>
  
  <pre><code>Exception:
     org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.builder.BuilderException: Error evaluating expression '#{item.value}'.  Return value ({[5800]=null}) was not iterable.
  </code></pre>
  
  <p>Where 5800 is a Integer-Value of the List</p>
  
  <p>Any help is appreciated!</p>