select c.tag ,round(count(c.uid)/(select count(distinct uid) from tb_user_log),2) as ratio from ( select a.uid ,case when timestampdiff(day,a.last_out,a.today_time) <=6 and b.last_out_times >1 then '忠实用户' when timestampdiff(day,a.last_out,a.today_t...