Hi 你可以看下这篇文章是否满足的你需求:
http://wuchong.me/blog/2020/02/25/demo-building-real-time-application-with-flink-sql
#统计一天每10分钟累计独立用户数

Best,
Jark


On Thu, 19 Mar 2020 at 23:30, hiliuxg <[email protected]> wrote:

> hi all:有这样子一个场景,我想通过每隔5分钟统计当日零点到当前5分钟的pv和uv,用批处理大概大概表达如下:
> select&nbsp; &nbsp;
> &nbsp;'2020-03-19' as dt ,&nbsp;&nbsp;
> &nbsp;'2020-03-19 12:05:00'&nbsp; as etltime ,
> &nbsp;count(1) as pv ,&nbsp;
> &nbsp;count(distinct userid) as uv&nbsp;
> from t_user_log&nbsp;
> where&nbsp; logintime&nbsp; &gt;= '2020-03-19 00:00:00' and logintime <
> '2020-03-19 12:05:00'&nbsp;
>
>
> 这里,没法用flink sql 处理,当时这种场景又特别多,各位大神有好的方案处理吗?

回复