Mybatis--association
①借助其它Mapper完成连表查询:
<association property="createUser" select="com.bd.dao.UserScInfoMapper.selectScUserNameById"
column="create_by">
</association>
说明:column是数据库字段,property为Java类属性。
②在本Mapper完成连表查询:
<collection property="nicInfoList"
ofType="com.bd.info.model.info.NicInfo"
column="{id=id, azId=az_id}" javaType="ArrayList" select="getNicInfoList">
</collection>
说明:ofType为列表类型,javaType为返回类型,select为查询体。(column是数据库字段,property为Java类属性)
标签:mapper,--,查询,column,Mybatis,id,association From: https://www.cnblogs.com/minaotor/p/17492823.html