Commit b362d5ce authored by litaolemo's avatar litaolemo

update

parent 9b8d6aac
......@@ -93,8 +93,9 @@ spark.sql("CREATE TEMPORARY FUNCTION arrayMerge AS 'com.gmei.hive.common.udf.UDF
# huidu_device_id_df = spark.sql(huidu_device_id_sql)
# huidu_device_id_df.createOrReplaceTempView("dev_view")
sql_search_ctr = r"""
select count(1) from (
SELECT partition_date,
card_content_type,
cl_id,
v.recommend_type,
count(card_id) as session_pv0,
......@@ -153,7 +154,7 @@ sql_search_ctr = r"""
app_session_id
)a
LATERAL VIEW explode (a.recommend_type) v as recommend_type
group by partition_date,card_content_type,cl_id,v.recommend_type
group by partition_date,cl_id,v.recommend_type having session_pv0 >= 4)
""".format(partition_day='20201105',end_date='20201025')
print(sql_search_ctr)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment