关于resultMap中的culumn
<resultMap id="唯一标识" class="定义实体类的别名">
<result property="对应的实体类的属性" column="对应的数据库中查询结果的字段" javaType="实体类属性的数据类型">
</resultMap >
例如:
```java
<select id="selectById" parameterClass="student" resultClass="student" >
select a name1,b name2 from (
select a,b,c from student where birthDate = 12/17
union all
select a,b,c from student where age = 18)
</select>
实体类应该是
public Student{
private String stuname;
private String birthdate;
....
}
相对应的resultMap 应该是
<resultMap id="唯一标识" class="定义实体类的别名">
<result property="stuname" column="name1" javaType="VARCHAR">
<result property="birthdate" column="name1" javaType="VARCHAR">
</resultMap >