mysql 查询统计按日期 人数


-- 需求:用户某天的充值人数和充值金额总和
select date_format(create_time,'%Y-%m-%d') as 日期, count(DISTINCT(product_user_id)) , sum(money_fen) from dts_pay_order where client_id = 64 and pay_status =2 and create_time >='2022-09-09 00:00:00' and create_time <'2022-09-10 00:00:00'

  

posted @ 2022-09-15 14:51  变换  阅读(61)  评论(0编辑  收藏  举报