mybatis will return a map that columnName is key,and columnValue as value.But the result map I want is that the key is the value of column 1, and the value is the value of column 2.
I use this to map,and it did'n work,and throw TooManyResultsException.
<resultMap id="countMap" type="HashMap">
<result property="key" column="column1"/>
<result property="value" column="column2"/>
</resultMap>