|
|
(select concat('{"x":',DATE_FORMAT(date_sub(now(),interval 3 MONTH),'%c'),',"y":',ifnull(ROUND(sum((ifnull(si_amount/10000,0))),2),'0'),'}') d4 from statsinfo where companyid=#{componyId} and si_yearmonth=DATE_FORMAT(date_sub(now(),interval 3 MONTH),'%Y%m') and si_type='PURC' ORDER BY si_amount desc) data_4,
|
|
(select concat('{"x":',DATE_FORMAT(date_sub(now(),interval 3 MONTH),'%c'),',"y":',ifnull(ROUND(sum((ifnull(si_amount/10000,0))),2),'0'),'}') d4 from statsinfo where companyid=#{componyId} and si_yearmonth=DATE_FORMAT(date_sub(now(),interval 3 MONTH),'%Y%m') and si_type='PURC' ORDER BY si_amount desc) data_4,
|
|
|
-(select concat('{"x":',DATE_FORMAT(date_sub(now(),interval 4 MONTH),'%Y%m'),',"y":',ifnull(ROUND(sum((ifnull(si_amount/10000,0))),2),'0'),'}') d5 from statsinfo where companyid=#{componyId} and si_yearmonth=DATE_FORMAT(date_sub(now(),interval 4 MONTH),'%Y%m') and si_type='PURC' ORDER BY si_amount desc)data_5,
|
|
|
|
|
|
|
+(select concat('{"x":',DATE_FORMAT(date_sub(now(),interval 4 MONTH),'%c'),',"y":',ifnull(ROUND(sum((ifnull(si_amount/10000,0))),2),'0'),'}') d5 from statsinfo where companyid=#{componyId} and si_yearmonth=DATE_FORMAT(date_sub(now(),interval 4 MONTH),'%Y%m') and si_type='PURC' ORDER BY si_amount desc)data_5,
|
|
|
(select concat('{"x":',DATE_FORMAT(date_sub(now(),interval 5 MONTH),'%c'),',"y":',ifnull(ROUND(sum((ifnull(si_amount/10000,0))),2),'0'),'}') d6 from statsinfo where companyid=#{componyId} and si_yearmonth=DATE_FORMAT(date_sub(now(),interval 5 MONTH),'%Y%m') and si_type='PURC' ORDER BY si_amount desc)data_6)
|
|
(select concat('{"x":',DATE_FORMAT(date_sub(now(),interval 5 MONTH),'%c'),',"y":',ifnull(ROUND(sum((ifnull(si_amount/10000,0))),2),'0'),'}') d6 from statsinfo where companyid=#{componyId} and si_yearmonth=DATE_FORMAT(date_sub(now(),interval 5 MONTH),'%Y%m') and si_type='PURC' ORDER BY si_amount desc)data_6)
|