https://blog.csdn.net/ao123056/article/details/79443788
demo:
SELECT YEAR(insert_time) AS year,
MONTH(insert_time) AS month,
count(*) as count
FROM tb1
WHERE YEAR(insert_time)=2019
GROUP BY YEAR(insert_time), MONTH(insert_time);
最后
以上就是帅气枕头最近收集整理的关于SQL 一年内每月数据统计的全部内容,更多相关SQL内容请搜索靠谱客的其他文章。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复