<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.yeejoin.equipmanage.mapper.EquipmentAlarmReportDayMapper">
    <select id="getOneByDateAndSpeIdAndAlarmType" resultType="com.yeejoin.equipmanage.common.entity.EquipmentAlarmReportDay">
        SELECT
        weard.id AS id,
        weard.org_code AS orgCode,
        weard.report_date AS reportDate,
        weard.equipment_specific_id AS equipmentSpecificId,
        weard.equipment_specific_name AS equipmentSpecificName,
        weard.system_ids AS systemIds,
        weard.alarm_type AS alarmType,
        weard.last_report_date AS lastReportDate,
        weard.frequency AS frequency,
        weard.create_date AS createDate,
        weard.update_date AS updateDate
        FROM wl_equipment_alarm_report_day weard
        WHERE weard.report_date = #{reportDate} AND weard.equipment_specific_id = #{speId} AND weard.alarm_type = #{alarmType}
    </select>
</mapper>