select count(1) value,date_format(down_time,'%m/%d') name,date(down_time) displayDate
from tb_download_detail
group by date(down_time) order by displayDate asc
select count(1) value,CONCAT(DATE_FORMAT(down_time,'%Y'),'-',DATE_FORMAT(down_time,'%v'),'周') name,
CONCAT(DATE_FORMAT(down_time,'%Y'),'-',DATE_FORMAT(down_time,'%v'),'周') displayDate from tb_download_detail
group by DATE_FORMAT(down_time,'%y%v') order by down_time asc
select count(1) value, DATE_FORMAT(down_time,'%y-%m') name,DATE_FORMAT(down_time,'%y-%m') displayDate from tb_download_detail
group by DATE_FORMAT(down_time,'%y-%m') order by down_time asc
select count(1) value, CONCAT(YEAR(down_time),'-',QUARTER(down_time),'季度') name,CONCAT(YEAR(down_time),'-',QUARTER(down_time),'季度') displayDate from tb_download_detail group by name order by down_time asc
select count(1) value,date_format(active_time,'%m/%d') name,date(active_time) displayDate from tb_water
where date(active_time) >= #{startTime} and date(active_time) <= #{endTime}
group by date(active_time) order by displayDate asc
select date_format(active_time,'%m/%d') name,date(active_time) displayDate,
(select sum(value) from (select count(1) value,date(active_time) display from tb_water group by date(active_time) ) a where a.display <= displayDate) as value from tb_water
where date(active_time) >= #{startTime} and date(active_time) <= #{endTime}
group by date(active_time) order by displayDate asc