(SELECT '待确认' eventStateLabel,count(*) num FROM dc_event where event_type = '1' and date_format(create_time,'%y%m') = date_format(now(),'%y%m') and event_state = '0')
from
UNION All
(select '0' eventState,'待确认' eventStateLabel
(SELECT '处理中' eventStateLabel,count(*) num FROM dc_event where event_type = '1' and date_format(start_time,'%y%m') = date_format(now(),'%y%m') and event_state = '1')
union all select '1' eventState,'处理中' eventStateLabel
UNION All
union all select '2' eventState,'已完成' eventStateLabel) t1
(SELECT '已完成' eventStateLabel,count(*) num FROM dc_event where event_type = '1' and date_format(end_time,'%y%m') = date_format(now(),'%y%m') and event_state = '2')
left join
(select event_state,count(*) num from dc_event
where event_type = '1' and date_format(start_time,'%y%m') = date_format(now(),'%y%m')