|
|
@@ -559,6 +559,11 @@
|
|
|
)t3 on t1.stat_date = t3.stat_date and t1.app_id = t3.ma_appid
|
|
|
)tb
|
|
|
</select>
|
|
|
+
|
|
|
+ <!--
|
|
|
+ if(m.stat_date >= 20251216,m.link_id,coalesce(m.link_id,t1.link_id,u.link_id)) link_id
|
|
|
+ 20251216完善了用户明细数据link_id等相关信息的补全操作,不需要再去关联查询
|
|
|
+ -->
|
|
|
<select id="runCPSIaaWxSettlementData" resultType="com.alibaba.fastjson.JSONObject">
|
|
|
select stat_date, link_id, app_id, person_id, person_pid, company_id,
|
|
|
ad_total_income, ad_play_user_count,
|
|
|
@@ -571,7 +576,7 @@
|
|
|
ifnull(user_count, 0) ad_play_user_count,
|
|
|
ifnull(ad_fund, 0) * (link_count/all_count) ad_amount
|
|
|
from (
|
|
|
- select m.stat_date,m.app_id,coalesce(m.link_id,t1.link_id,u.link_id) link_id, count(*) link_count,
|
|
|
+ select m.stat_date,m.app_id,if(m.stat_date >= 20251216,m.link_id,coalesce(m.link_id,t1.link_id,u.link_id)) link_id, count(*) link_count,
|
|
|
count(distinct m.login_id) user_count
|
|
|
from hr_playlet.mp_event m
|
|
|
left join
|