sql 1天保留关键绩效指标

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了sql 1天保留关键绩效指标相关的知识,希望对你有一定的参考价值。

\!h 1 Day Retention
-- How many players are returning to play the next day
select
  date(g1.created_at) as dt, 
  round(100 * count(distinct g2.user_id) / -- retained users / total users
    count(distinct g1.user_id)) as retention 
from gameplays as g1
  left join gameplays as g2 on
    g1.user_id = g2.user_id
    and date(g1.created_at) = date(datetime(g2.created_at, '-1 day'))
group by 1
order by 1
limit 100;

以上是关于sql 1天保留关键绩效指标的主要内容,如果未能解决你的问题,请参考以下文章

关键绩效指标法的IT服务的关键绩效指标法

KPI

理解Scrum 度量和关键绩效指标

如何选择你的移动APP KPIs(关键绩效指标)

KPI考核

总结整理互联网名词