1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- <?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.ruoyi.predict.mapper.NoscaleWfDaPfPeriodDataMapper">
- <resultMap type="NoscaleWfDaPfPeriodData" id="NoscaleWfDaPfPeriodDataResult">
- <result property="windplantNo" column="windplant_no"/>
- <result property="modelNo" column="model_no"/>
- <result property="dataTime" column="data_time"/>
- <result property="value" column="value"/>
- <result property="dataFlag" column="data_flag"/>
- <result property="modspeed" column="modspeed"/>
- </resultMap>
- <sql id="selectNoscaleWfDaPfPeriodDataVo">
- select windplant_no, model_no, data_time, value, data_flag, modspeed from noscale_wf_da_pf_period_data
- </sql>
- <select id="selectNoscaleWfDaPfPeriodDataList" parameterType="NoscaleWfDaPfPeriodData"
- resultMap="NoscaleWfDaPfPeriodDataResult">
- <include refid="selectNoscaleWfDaPfPeriodDataVo"/>
- <where>
- <if test="windplantNo != null ">and windplant_no = #{windplantNo}</if>
- <if test="modelNo != null ">and model_no = #{modelNo}</if>
- <if test="value != null ">and value = #{value}</if>
- <if test="dataFlag != null ">and data_flag = #{dataFlag}</if>
- <if test="modspeed != null ">and modspeed = #{modspeed}</if>
- <if test="params.beginDataTime != null and params.beginDataTime != '' and params.endDataTime != null and params.endDataTime != ''">
- and data_time between to_date(#{params.beginDataTime},'yyyy-MM-dd HH24:MI:SS') and
- to_date(#{params.endDataTime},'yyyy-MM-dd HH24:MI:SS')
- </if>
- <!--<if test="params.beginDataTime != null and params.beginDataTime != ''">
- and data_time >= to_date(#{params.beginDataTime},'yyyy-MM-dd HH24:MI:SS')
- </if>-->
- <if test="dataTime != null ">and data_time = #{dataTime}</if>
- <if test="condition != null ">and to_char(data_time,'yyyy-MM-dd HH24:MI:SS') LIKE '%00:00:00%'</if>
- </where>
- order by data_time asc
- </select>
- <select id="selectNoscaleWfDaPfPeriodDataById" parameterType="Long" resultMap="NoscaleWfDaPfPeriodDataResult">
- <include refid="selectNoscaleWfDaPfPeriodDataVo"/>
- where windplant_no = #{windplantNo}
- </select>
- <select id="selectNoscaleWfDaPfPeriodDataByJh" parameterType="NoscaleWfDaPfPeriodData" resultMap="NoscaleWfDaPfPeriodDataResult">
- <include refid="selectNoscaleWfDaPfPeriodDataVo"/>
- where windplant_no = #{windplantNo} and model_no = #{modelNo} and data_time = #{dataTime}
- </select>
- <select id="selectNoscaleWfDaPfPeriodData" parameterType="NoscaleWfDaPfPeriodData" resultMap="NoscaleWfDaPfPeriodDataResult">
- <include refid="selectNoscaleWfDaPfPeriodDataVo"/>
- where windplant_no = #{windplantNo} and model_no = #{modelNo} and data_time > #{dataTime}
- </select>
- </mapper>
|