| | |
| | | </where> |
| | | ORDER BY the_date DESC, equipment_id ASC |
| | | </select> |
| | | |
| | | <select id="findByEquIdsAndDate" resultType="java.math.BigDecimal"> |
| | | SELECT |
| | | AVG ( oee ) |
| | | FROM |
| | | mdc_oee_info |
| | | <where> |
| | | the_date = #{date} |
| | | AND equipment_id IN |
| | | <foreach collection="equipmentIdList" item="id" index="index" open="(" close=")" separator=","> |
| | | #{ id } |
| | | </foreach> |
| | | </where> |
| | | </select> |
| | | |
| | | <select id="findByEquIdAndDate" resultType="java.math.BigDecimal"> |
| | | SELECT oee FROM mdc_oee_info WHERE the_date = #{date} AND equipment_id = #{equipmentId} |
| | | </select> |
| | | |
| | | <select id="findByEquIdAndMonth" resultType="java.math.BigDecimal"> |
| | | SELECT |
| | | AVG(oee) |
| | | FROM |
| | | mdc_oee_info |
| | | WHERE |
| | | the_date LIKE CONCAT(#{month}, '%') |
| | | AND equipment_id = #{equipmentId} |
| | | </select> |
| | | </mapper> |