select userid, substr(indate,1,10) as day,count(*) as products from ybdw_productInfo_unique_d
where sta = 0 and isshelvesnow = 1
group by substr(indate,1,10),userid;
会出现这样的重复数据
userid, day, products
726651 2019/1/15 4
726651 2019/1/15 4
726651 2018/12/21 1
726651 2018/12/21 1
726651 2019/1/4 4
726651 2019/1/4 4
726651 2018/12/20 1
726651 2018/12/20 1