时间段统计========== 按年汇总,统计:select sum(mymoney) as totalmoney, count(*) as sheets from mytable group by date_format(col, '%Y'); 按月汇总,统计:select sum(mymoney) as totalmoney, count(*) as sheets from mytable group by date_format(col, '%Y-%m'); 按季度汇总,统计:select…