Mapperéé¢è¿åListï¼å°±æ¯è¯´Mapperéé¢çæ¹æ³å£°ææ¯
public List
daoãserviceå±ä¹ä½ç¸åºä¿®æ¹ï¼æ¹ä¸ºè¿åList<Map<String,Object>>
<mapper namespace="com.brkc.epolice.mysql.dao.OnlineStatMapper" >
<select id="selectOnlineRateCurrent" resultType="java.util.HashMap" >
SELECT count(*) value, c. NAME label, ifnull(b.device_status, 0) device_status
FROM td01_device a
LEFT OUTER JOIN td06_device_status b ON a.id = b.device_id
LEFT OUTER JOIN td05_dd_device_status c ON c.ID = ifnull(b.device_status, 0)
GROUP BY ifnull(b.device_status, 0), c. NAME
ORDER BY device_status
</select>
</mapper>
public interface OnlineStatMapper {
public List<Map<String, Object>> selectOnlineRateCurrent();
}