title: mybatis iterate through map and execute multiple select statements
body: <p>I would like to pass in a map and use mybatis to iterate through the map and execute multiple select statements and collect the results in a map. Is this possible? The below does an AND as one query.</p>
  
  <pre><code>&lt;select id="populate" parameterType="Map" resultType="hashmap"&gt;
      &lt;foreach collection="dataMap" index="key" item="value" open=""
          separator=" and " close=""&gt;
      select count(*) as countS from tabl where
  
          id LIKE #{key,jdbcType=VARCHAR} || '%'
      &lt;/foreach&gt;
  &lt;/select&gt;
  </code></pre>