Browse Source

盯盘2.0功能 修改为查询当天账户数量

zhaoxian 4 years ago
parent
commit
50fa365cde

+ 4 - 1
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/report/mapper/xml/EtlKuaishouReportAccountHourlyMapper.xml

@@ -437,7 +437,10 @@
         ctop_etl_kuaishou_report_account_hourly t1
         LEFT JOIN ctop_user_allocation t2 ON t1.account_id = t2.account_id
         LEFT JOIN(
-        SELECT user_id,COUNT(1) 'accountCount' FROM ctop_user_allocation WHERE
+        SELECT user_id,COUNT(1) 'accountCount' FROM ctop_user_allocation i1
+        INNER JOIN ctop_etl_kuaishou_report_account_hourly  i2 ON i1.account_id = i2.account_id
+        AND i2.stat_date = #{today}
+        WHERE
         account_status = 0 AND user_id IN
         <foreach item="id" index="index" collection="userIds"
                  open="(" separator="," close=")">