src/main/resources/mapping/VocValsMapper.xml
@@ -10,14 +10,10 @@ </resultMap> <select id="selectByTime" resultMap="selectMap"> select * select x, y, cast(val as decimal(12, 3)) "val" from voc_vals <where> date_format(create_time, '%Y%m%d%H') = ${time} <if test="startVal != null"> and val > ${startVal} </if> </where> where date_format(create_time, '%Y%m%d%H') = ${time} and val > (select jcyj from alert_config); </select> <select id="countByTime" resultType="java.lang.Integer">