title: How can I populate parameters map with result set in MyBatis
body: <p>I'm reading a book "MyBatis in Practice" and can not figure why the code at page 67-68 doesn't work. Here is the problem. It's about calling stored procedures and it works but the real problem is that I can not figure out how to populate input map with result set. So here is the code from the main class:</p>
  
  <pre><code>public void callReadAllPets() throws Exception {
      HashMap&lt;String, List&lt;PetDVO&gt;&gt; inputMap = new HashMap&lt;String, List&lt;PetDVO&gt;&gt;();
      List&lt;PetDVO&gt; petList = new ArrayList&lt;PetDVO&gt;();
      inputMap.put("petData", petList);
      //
      getSqlSession().selectList("callReadAllPets", inputMap);
      List&lt;PetDVO&gt; outputData = inputMap.get("petData");
      printResultList(outputData, "read_all_pets");
  }
  
  private void printResultList(List&lt;PetDVO&gt; list) {
      for (PetDVO item : list) {
          System.out.println("     owner: " + item.getOwner());
          System.out.println("   species: " + item.getSpecies());
          System.out.println("       sex: " + item.getSex());
      }
  }
  </code></pre>
  
  <p>PetDVO is just a Java POJO.
  Here is the code from mapper.xml</p>
  
  <pre><code>&lt;select id="callReadAllPets" resultType="PetDVO" statementType="CALLABLE"&gt;
   CALL read_all_pets('SELECT name, owner, species, sex, birth, death FROM pet')
  </code></pre>
  
  <p>
  After running previous code, the outputData list is empty, i.e. unpopulated with results. This is the way suggested in the book but it doesn't work for me? How can I solve this?
  p.s.
  I'm using MyBatis 3.2.3</p>