title: MyBatis select statement WITHOUT a resultMap
body: <p>I'm trying to avoid using resultMap's in MyBatis (or preferably without XML altogether).</p>
  
  <p>I have the following working:</p>
  
  <pre><code>     &lt;select id="getAllSales" resultType="Sales"&gt;
              SELECT TOP 100
                  ID as "id",
                  PLANE as "plane",
                  PLANE_TYPE as "plane_type"
          FROM SALES
       &lt;/select&gt;
  </code></pre>
  
  <p>This maps to a domain object (POJO) without issue. However, if I have a child domain object, there doesn't seem to be any info out there how to make this work. For example:</p>
  
  <pre><code>&lt;select id="getAllSales" resultType="Sales"&gt;
                  SELECT TOP 100
                      ID as "id",
                      PLANE as "plane.type",
                      PLANE_TYPE as "plane.type.serial_num"
              FROM SALES
   &lt;/select&gt;
  </code></pre>
  
  <p>This will not map with a resultMap="Sales" attribute (Sales object is the parent object and contains the "Plane" type or, more specifically a List type.</p>
  
  <p>Any suggestion or ideas on how to get away from using a resultMap within the XML file?</p>
  
  <p>Even more desirable, would be to go away from XML files completely and use @ annotations in the interface.</p>
  
  <p>Thank you.</p>