sql两个日期之间的查询统计

sql查询统计

  sql语句:

      select count(code) as '统计',create_time as '订单时间' from sp_orders where datediff(create_time,'2017-06-06')>=0 and datediff(create_time,'2017-09-09')<=0 group by month(create_time)

  查询结果:

  

 

posted on 2017-08-14 09:49  不好说  阅读(1067)  评论(0编辑  收藏  举报

导航