节能减排

This commit is contained in:
jiang 2025-07-24 23:13:56 +08:00
parent 62045c3d26
commit a142426be3
1 changed files with 2 additions and 1 deletions

View File

@ -10,7 +10,8 @@
SUM(consumption_kwh) AS consumptionKwh,
SUM(renewable_used_kwh * 0.9) AS renewableUsedKwh
FROM device_energy_analysis
WHERE stat_date BETWEEN #{startDate} AND #{endDate}
WHERE stat_date >= #{startDate}
AND stat_date < DATE_ADD(#{endDate}, INTERVAL 1 DAY)
and pro_id = #{proId}
GROUP BY DATE(stat_date)
ORDER BY statDate ASC