PvDaPfDayDataMapper.xml 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!DOCTYPE mapper
  3. PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
  4. "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  5. <mapper namespace="com.ruoyi.predict.mapper.PvDaPfDayDataMapper">
  6. <resultMap type="PvDaPfDayData" id="PvDaPfDayDataResult">
  7. <result property="pvplantNo" column="pvplant_no" />
  8. <result property="modelNo" column="model_no" />
  9. <result property="dataTime" column="data_time" />
  10. <result property="nrmse" column="nrmse" />
  11. <result property="nmae" column="nmae" />
  12. <result property="bias" column="bias" />
  13. <result property="correlationCoeff" column="correlation_coeff" />
  14. <result property="accuracyRate" column="accuracy_rate" />
  15. <result property="dataCount" column="data_count" />
  16. <result property="dataFlag" column="data_flag" />
  17. </resultMap>
  18. <sql id="selectPvDaPfDayDataVo">
  19. select pvplant_no, model_no, data_time, nrmse, nmae, bias, correlation_coeff, accuracy_rate, data_count, data_flag from pv_da_pf_day_data
  20. </sql>
  21. <select id="selectPvDaPfDayDataList" parameterType="PvDaPfDayData" resultMap="PvDaPfDayDataResult">
  22. <include refid="selectPvDaPfDayDataVo"/>
  23. <where>
  24. <if test="pvplantNo != null ">and pvplant_no = #{pvplantNo}</if>
  25. <if test="modelNo != null ">and model_no = #{modelNo}</if>
  26. <if test="nrmse != null "> and nrmse = #{nrmse}</if>
  27. <if test="nmae != null "> and nmae = #{nmae}</if>
  28. <if test="bias != null "> and bias = #{bias}</if>
  29. <if test="correlationCoeff != null "> and correlation_coeff = #{correlationCoeff}</if>
  30. <if test="accuracyRate != null "> and accuracy_rate = #{accuracyRate}</if>
  31. <if test="dataCount != null "> and data_count = #{dataCount}</if>
  32. <if test="dataFlag != null "> and data_flag = #{dataFlag}</if>
  33. <if test="params.beginDataTime != null and params.beginDataTime != '' and params.endDataTime != null and params.endDataTime != ''">
  34. and data_time between to_date(#{params.beginDataTime},'yyyy-MM-dd HH24:MI:SS') and
  35. to_date(#{params.endDataTime},'yyyy-MM-dd HH24:MI:SS')
  36. </if>
  37. <if test="dataTime != null ">and data_time = #{dataTime}</if>
  38. </where>
  39. </select>
  40. <select id="selectPvDaPfDayDataById" parameterType="Long" resultMap="PvDaPfDayDataResult">
  41. <include refid="selectPvDaPfDayDataVo"/>
  42. where pvplant_no = #{pvplantNo}
  43. </select>
  44. </mapper>