Commit 44ac8423 authored by lisong's avatar lisong

修改bug

parent 1acf518f
......@@ -2378,7 +2378,7 @@
WHEN max( CASE WHEN ei.equipment_index_key = 'FHS_FirePoolDevice_WaterLevel' THEN ei.`value` END ) < IFNULL( rp.min_water_level, 0 )
AND rp.max_water_level IS NULL THEN
'--' ELSE IFNULL((
TRUNCATE (
FORMAT(
abs(
IFNULL(
max( CASE WHEN ei.equipment_index_key = 'FHS_FirePoolDevice_WaterLevel' THEN ei.`value` END ),
......@@ -2792,7 +2792,7 @@
(
count( a.id ) - count( a.alarmNum > 0 OR NULL )) AS normalNum,
(
TRUNCATE (
FORMAT (
abs(((
count( a.id ) - count( a.alarmNum > 0 OR NULL )) /
IF
......@@ -2822,7 +2822,7 @@
count( a.nowLevel < a.minLevel OR NULL ) AS abnomalNum,
count( a.nowLevel >= a.minLevel OR NULL ) AS nomalNum,
(
TRUNCATE (
FORMAT (
abs(((
count( a.nowLevel >= a.minLevel OR NULL )) /
IF
......@@ -2921,7 +2921,7 @@
<select id="getCarInfo" resultType="java.util.Map">
select b.*,
(TRUNCATE (
(FORMAT (
abs((
b.near7DaysStartNum) /
IF
......@@ -3982,8 +3982,8 @@
if (SUM(a1.lastAlarmNum)>0,IFNULL( convert( ABS(SUM(a1.alarmNum)-SUM(a1.lastAlarmNum))/SUM(a1.lastAlarmNum),char(5)),'-'),ABS(SUM(a1.alarmNum)-SUM(a1.lastAlarmNum)))*100 as alarmWOW,
(CASE WHEN (SUM(a1.exepctionNum)-SUM(a1.lastExepctionNum)) &lt;0 THEN '减少' else '增加' end ) as status1,
(CASE WHEN (SUM(a1.alarmNum)-SUM(a1.lastAlarmNum)) &lt;0 THEN '减少' else '增加' end ) as status2,
TRUNCATE(if(SUM(a1.num)>0, convert(SUM(a1.num - a1.exepctionNum)/SUM(a1.num),char(5)), SUM(a1.num - a1.exepctionNum))*100, 2) as normalRate,
TRUNCATE(if(SUM(a1.num)>0,convert(SUM(a1.faultNum)/SUM(a1.num),char(5)),SUM(a1.faultNum)) *100, 2) as faultRate,
FORMAT(if(SUM(a1.num)>0, convert(SUM(a1.num - a1.exepctionNum)/SUM(a1.num),char(5)), SUM(a1.num - a1.exepctionNum))*100, 2) as normalRate,
FORMAT(if(SUM(a1.num)>0,convert(SUM(a1.faultNum)/SUM(a1.num),char(5)),SUM(a1.faultNum)) *100, 2) as faultRate,
a1.create_date
from
(SELECT
......@@ -4233,7 +4233,7 @@
a1.systemName,
a1.system_id,
a1.alarmNum,
TRUNCATE(if( SUM(a1.num)>0,SUM(a1.num - a1.exepctionNum)/SUM(a1.num),SUM(a1.num - a1.exepctionNum))*100,2) as normalRate,
FORMAT(if( SUM(a1.num)>0,SUM(a1.num - a1.exepctionNum)/SUM(a1.num),SUM(a1.num - a1.exepctionNum))*100,2) as normalRate,
a1.create_date
from
(SELECT
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment