select crm.app_time , count(distinct crm.app_clientusernum) from connectrecord_mobile crm , clientuser_mobile cum , app_clientinfo ci where crm.app_clientusernum = cum.app_clientusernum and cum.app_clientid = ci.app_id and  crm.app_time between '2012-01-01 00:00:00' and '2013-01-01 23:59:59' and ci.app_enterid = 52 group by STR_TO_DATE(crm.app_time,'%Y-%m-%d');优化mysql