select year(time) 年,month(time) 月,day(time) 日,sum(num) from tablegroup by year(time),month(time),day(time)或者select convert(char(8),time,112) dt,sum(num) from tablegroup by convert(char(8),time,112)
posted on 2018-02-11 15:09 凤鸣岐山 阅读(73) 评论(0) 收藏 举报
博客园 © 2004-2025 浙公网安备 33010602011771号 浙ICP备2021040463号-3