|select '${stat_date}' as stat_date, count(cid_id) as clk_count_oldUser_Contrast
|select '${stat_date}' as stat_date, count(jd.cid_id) as clk_count_oldUser
|from data_feed_click jd inner join device_id_old
|on jd.device_id = device_id_old.device_id
|where (jd.cid_type = 'diary' or jd.cid_type = 'diary_video')
...
...
@@ -87,7 +87,7 @@ object temp_count {
valimp_count_oldUser=sc.sql(
s"""
|select '${stat_date}' as stat_date, count(cid_id) as imp_count_oldUser_Contrast
|select '${stat_date}' as stat_date, count(cid_id) as imp_count_oldUser
|from data_feed_exposure je inner join device_id_old
|on je.device_id = device_id_old.device_id
|where je.cid_type = 'diary'
...
...
@@ -99,9 +99,9 @@ object temp_count {
valclk_count_all=sc.sql(
s"""
|select '${stat_date}' as stat_date, count(cid_id) as clk_count_oldUser_all
|select '${stat_date}' as stat_date, count(cid_id) as clk_count_all
|from data_feed_click
|where (jd.cid_type = 'diary' or jd.cid_type = 'diary_video')
|where (cid_type = 'diary' or cid_type = 'diary_video')
|and device_id not in (select device_id from blacklist)
|and city_id in ("huzhou","liuan","zhenjiang","taizhou","jiaxing","weihai","maanshan","changzhou","shantou","nantong","yantai","wuxi","huhehaote","taiyuan","xining","yinchuan")
|and stat_date ='${stat_date}'
...
...
@@ -110,7 +110,7 @@ object temp_count {
valimp_count__all=sc.sql(
s"""
|select '${stat_date}' as stat_date, count(cid_id) as imp_count_oldUser_all
|select '${stat_date}' as stat_date, count(cid_id) as imp_count_all
|from data_feed_exposure
|where cid_type = 'diary'
|and device_id not in (select device_id from blacklist)