class xxDTO {
private Long id;
private Set<Long> industryIds;
private Set<Long> labelIds;
}
<resultMap id="articleMap" type="xxDTO" autoMapping="true">
<result property="id" column="ID"/>
<collection property="industryIds" ofType="long">
<result column="IndustryID"/>
</collection>
<collection property="labelIds" ofType="long">
<result column="LabelID"/>
</collection>
</resultMap>
select xx.ID,a.IndustryID,b.LableID from xx
left join a on ..
left join b on ..