Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
B
bi-report
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
data
bi-report
Commits
ff38c720
Commit
ff38c720
authored
Sep 27, 2020
by
魏艺敏
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'weiyimin' into 'master'
push codes See merge request
!68
parents
c780dc25
085a9bf6
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
4 deletions
+9
-4
daily_recommend_strategy.sql
pm/daily_recommend_strategy/etl/daily_recommend_strategy.sql
+4
-4
key_data.sql
pm/daily_userpost/report/key_data.sql
+4
-0
sign_daily.sql
pm/sign_daily/etl/sign_daily.sql
+1
-0
No files found.
pm/daily_recommend_strategy/etl/daily_recommend_strategy.sql
View file @
ff38c720
...
...
@@ -69,7 +69,7 @@ FROM
when
card_content_type
in
(
'special_pool'
)
then
'special'
else
card_content_type
end
as
card_content_type
,
CASE
when
transaction_type
in
(
'fmctr'
)
then
array
(
'fmctr'
,
'合计'
)
when
transaction_type
in
(
'high_quality_fmctr'
)
then
array
(
'high_quality_fmctr'
,
'合计'
)
WHEN
(
transaction_type
like
'%ctr'
and
transaction_type
not
in
(
'high_quality_ctr'
))
THEN
array
(
'ctr预估'
,
'合计'
)
WHEN
(
transaction_type
like
'%ctr'
and
transaction_type
not
in
(
'high_quality_ctr'
,
'high_quality_fmctr'
,
'fmctr'
))
THEN
array
(
'ctr预估'
,
'合计'
)
when
transaction_type
in
(
'high_quality_ctr'
)
then
array
(
'high_quality_ctr'
,
'合计'
)
WHEN
transaction_type
like
'%cvr'
THEN
array
(
'cvr预估'
,
'合计'
)
WHEN
transaction_type
in
(
'-1'
,
'smr'
)
THEN
array
(
'smr'
,
'合计'
)
...
...
@@ -99,7 +99,7 @@ FROM
cl_id
,
CASE
when
transaction_type
in
(
'fmctr'
)
then
array
(
'fmctr'
,
'合计'
)
when
transaction_type
in
(
'high_quality_fmctr'
)
then
array
(
'high_quality_fmctr'
,
'合计'
)
WHEN
(
transaction_type
like
'%ctr'
and
transaction_type
not
in
(
'high_quality_ctr'
))
THEN
array
(
'ctr预估'
,
'合计'
)
WHEN
(
transaction_type
like
'%ctr'
and
transaction_type
not
in
(
'high_quality_ctr'
,
'high_quality_fmctr'
,
'fmctr'
))
THEN
array
(
'ctr预估'
,
'合计'
)
when
transaction_type
in
(
'high_quality_ctr'
)
then
array
(
'high_quality_ctr'
,
'合计'
)
WHEN
transaction_type
like
'%cvr'
THEN
array
(
'cvr预估'
,
'合计'
)
WHEN
transaction_type
in
(
'-1'
,
'smr'
)
THEN
array
(
'smr'
,
'合计'
)
...
...
@@ -134,7 +134,7 @@ FROM
when
params
[
'card_content_type'
]
in
(
'special_pool'
)
then
'special'
else
params
[
'card_content_type'
]
end
as
card_content_type
,
CASE
when
params
[
'transaction_type'
]
in
(
'fmctr'
)
then
array
(
'fmctr'
,
'合计'
)
when
params
[
'transaction_type'
]
in
(
'high_quality_fmctr'
)
then
array
(
'high_quality_fmctr'
,
'合计'
)
WHEN
(
params
[
'transaction_type'
]
like
'%ctr'
and
params
[
'transaction_type'
]
not
in
(
'high_quality_ctr'
))
THEN
array
(
'ctr预估'
,
'合计'
)
WHEN
(
params
[
'transaction_type'
]
like
'%ctr'
and
params
[
'transaction_type'
]
not
in
(
'high_quality_ctr'
,
'high_quality_fmctr'
,
'fmctr'
))
THEN
array
(
'ctr预估'
,
'合计'
)
when
params
[
'transaction_type'
]
in
(
'high_quality_ctr'
)
then
array
(
'high_quality_ctr'
,
'合计'
)
WHEN
params
[
'transaction_type'
]
like
'%cvr'
THEN
array
(
'cvr预估'
,
'合计'
)
WHEN
params
[
'transaction_type'
]
in
(
'-1'
,
'smr'
)
THEN
array
(
'smr'
,
'合计'
)
...
...
@@ -163,7 +163,7 @@ FROM
when
params
[
'card_content_type'
]
in
(
'special_pool'
)
then
'special'
else
params
[
'card_content_type'
]
end
,
CASE
when
params
[
'transaction_type'
]
in
(
'fmctr'
)
then
array
(
'fmctr'
,
'合计'
)
when
params
[
'transaction_type'
]
in
(
'high_quality_fmctr'
)
then
array
(
'high_quality_fmctr'
,
'合计'
)
WHEN
(
params
[
'transaction_type'
]
like
'%ctr'
and
params
[
'transaction_type'
]
not
in
(
'high_quality_ctr'
))
THEN
array
(
'ctr预估'
,
'合计'
)
WHEN
(
params
[
'transaction_type'
]
like
'%ctr'
and
params
[
'transaction_type'
]
not
in
(
'high_quality_ctr'
,
'high_quality_fmctr'
,
'fmctr'
))
THEN
array
(
'ctr预估'
,
'合计'
)
when
params
[
'transaction_type'
]
in
(
'high_quality_ctr'
)
then
array
(
'high_quality_ctr'
,
'合计'
)
WHEN
params
[
'transaction_type'
]
like
'%cvr'
THEN
array
(
'cvr预估'
,
'合计'
)
WHEN
params
[
'transaction_type'
]
in
(
'-1'
,
'smr'
)
THEN
array
(
'smr'
,
'合计'
)
...
...
pm/daily_userpost/report/key_data.sql
View file @
ff38c720
...
...
@@ -15,6 +15,10 @@ SELECT post_id as `帖子id`
,
nvl
(
concat
(
round
(
page_pv_20s_10
/
page_pv_10
*
100
,
2
),
'%'
),
0
)
as
`前10日浏览20s以上pv/前10日总浏览pv`
,
nvl
(
exp_pv_10
,
0
)
as
`前10日曝光`
,
nvl
(
avg_page_stay_10
,
0
)
as
`前10日平均阅读时长(s)`
,
nvl
(
concat
(
round
(
click_pv
/
exp_pv
*
100
,
2
),
'%'
),
0
)
as
`历史ctr`
,
nvl
(
concat
(
round
(
page_pv_20s
/
page_pv
*
100
,
2
),
'%'
),
0
)
as
`历史浏览20s以上pv/历史总浏览pv`
,
nvl
(
exp_pv
,
0
)
as
`历史曝光`
,
nvl
(
avg_page_stay
,
0
)
as
`历史平均阅读时长(s)`
FROM
pm
.
tl_pm_userpost_d_v2
where
partition_day
=
regexp_replace
(
DATE_SUB
(
current_date
,
1
)
,
'-'
,
''
)
order
by
`前10日曝光`
desc
...
...
pm/sign_daily/etl/sign_daily.sql
View file @
ff38c720
...
...
@@ -157,6 +157,7 @@ LEFT JOIN
FROM
tl
.
tl_gm_sl_lead_task
--线索任务表(用户点击授权后记入该表)
WHERE
partition_day
=
regexp_replace
(
date_sub
(
current_date
(),
1
),
'-'
,
''
)
AND
source
=
'2'
--用户行为电话授权
AND
(
user_id
is
NOT
NULL
or
USER_ID
<>
''
)
)
e
ON
d
.
lead_task_id
=
e
.
id
GROUP
BY
user_id
,
merchant_id
,
regexp_replace
(
SUBSTR
(
a
.
partition_date
,
1
,
6
),
'-'
,
''
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment