<?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.njcn.prepare.harmonic.mapper.mysql.line.RMpMeasureReportDPOMapper">
    <select id="getMaxFrequencyDeviation" resultType="double">
        SELECT
            IFNULL(max( frequency_deviation_max ),0)
        FROM
            `r_mp_measure_report_d`
        WHERE
        measurement_point_id = #{lineId}
        <![CDATA[AND data_date = #{date}]]>
    </select>

    <select id="getMaxUnbalance95" resultType="double">
        SELECT
            IFNULL(max( NEGATIVE_SEQUENCE_VOLTAGE_UNBALANCE_95 ),0)
        FROM
            `r_mp_measure_report_d`
        WHERE
        measurement_point_id = #{lineId}
        <![CDATA[AND data_date = #{date}]]>
    </select>
</mapper>