这个可以使用sum函数去实现 返回来的就是这段时间内所有数字的总和select sum('个数') from '表名' where '时间' between '时间一' and '时间二';
加个辅助的date表,left join查询