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
f219b157
Commit
f219b157
authored
Aug 11, 2020
by
魏艺敏
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
push codes
parent
95479fce
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
17 additions
and
6 deletions
+17
-6
daily_recommend_strategy.sql
pm/daily_recommend_strategy/etl/daily_recommend_strategy.sql
+10
-4
step2.job
pm/kyc_q2/job/step2.job
+1
-2
ai_daily.sql
pm/kyc_q2/report/ai_daily.sql
+2
-0
ai_qa.sql
pm/kyc_q2/report/ai_qa.sql
+2
-0
kyc_qa_daily.sql
pm/kyc_q2/report/kyc_qa_daily.sql
+2
-0
No files found.
pm/daily_recommend_strategy/etl/daily_recommend_strategy.sql
View file @
f219b157
...
...
@@ -69,6 +69,7 @@ FROM
when
transaction_type
in
(
'samecity_ctr'
)
then
'samecity_ctr'
when
transaction_type
in
(
'samecity_cvr'
,
'samecity_ctcvr'
)
then
'samecity_cvr'
when
transaction_type
in
(
'hotspot_feed'
)
then
'hotspot_feed'
when
transaction_type
in
(
'fmctr'
)
then
'fmctr'
END
AS
recommend_type
,
card_id
,
app_session_id
...
...
@@ -78,7 +79,8 @@ FROM
AND
is_exposure
=
'1'
----精准曝光
AND
page_name
=
'home'
AND
tab_name
=
'精选'
AND
transaction_type
in
(
'-1'
,
'ctr'
,
'smr'
,
'cvr'
,
'ctcvr'
,
'hotspot'
,
'pgc'
,
'newdata'
,
'samecity_ctr'
,
'samecity_cvr'
,
'hotspot_feed'
,
'samecity_ctcvr'
)
AND
(
transaction_type
in
(
'-1'
,
'smr'
,
'hotspot'
,
'pgc'
,
'newdata'
,
'samecity_ctr'
,
'samecity_cvr'
,
'hotspot_feed'
,
'samecity_ctcvr'
,
'fmctr'
)
or
(
transaction_type
in
(
'ctr'
,
'cvr'
,
'ctcvr'
)
and
card_content_type
in
(
'qa'
,
'answer'
,
'user_post'
)))
AND
card_content_type
in
(
'qa'
,
'diary'
,
'user_post'
,
'answer'
)
group
by
partition_date
,
case
when
card_content_type
in
(
'qa'
,
'answer'
)
then
'qa'
else
card_content_type
end
,
...
...
@@ -90,7 +92,8 @@ FROM
when
transaction_type
in
(
'newdata'
)
then
'保量卡片'
when
transaction_type
in
(
'samecity_ctr'
)
then
'samecity_ctr'
when
transaction_type
in
(
'samecity_cvr'
,
'samecity_ctcvr'
)
then
'samecity_cvr'
when
transaction_type
in
(
'hotspot_feed'
)
then
'hotspot_feed'
END
,
when
transaction_type
in
(
'hotspot_feed'
)
then
'hotspot_feed'
when
transaction_type
in
(
'fmctr'
)
then
'fmctr'
END
,
card_id
,
app_session_id
)
a
...
...
@@ -118,6 +121,7 @@ FROM
when
params
[
'transaction_type'
]
in
(
'samecity_ctr'
)
then
'samecity_ctr'
when
params
[
'transaction_type'
]
in
(
'samecity_cvr'
,
'samecity_ctcvr'
)
then
'samecity_cvr'
when
params
[
'transaction_type'
]
in
(
'hotspot_feed'
)
then
'hotspot_feed'
when
params
[
'transaction_type'
]
in
(
'fmctr'
)
then
'fmctr'
END
AS
recommend_type
,
params
[
'card_id'
]
as
card_id
,
app_session_id
...
...
@@ -126,7 +130,8 @@ FROM
AND
action
=
'on_click_card'
AND
params
[
'page_name'
]
=
'home'
AND
params
[
'tab_name'
]
=
'精选'
AND
params
[
'transaction_type'
]
in
(
'-1'
,
'ctr'
,
'smr'
,
'cvr'
,
'ctcvr'
,
'hotspot'
,
'pgc'
,
'newdata'
,
'samecity_ctr'
,
'samecity_cvr'
,
'hotspot_feed'
,
'samecity_ctcvr'
)
AND
(
params
[
'transaction_type'
]
in
(
'-1'
,
'smr'
,
'hotspot'
,
'pgc'
,
'newdata'
,
'samecity_ctr'
,
'samecity_cvr'
,
'hotspot_feed'
,
'samecity_ctcvr'
,
'fmctr'
)
or
(
params
[
'transaction_type'
]
in
(
'ctr'
,
'cvr'
,
'ctcvr'
)
and
params
[
'card_content_type'
]
in
(
'qa'
,
'answer'
,
'user_post'
)))
AND
params
[
'card_content_type'
]
in
(
'qa'
,
'diary'
,
'user_post'
,
'answer'
)
GROUP
BY
partition_date
,
cl_id
,
...
...
@@ -138,7 +143,8 @@ FROM
when
params
[
'transaction_type'
]
in
(
'newdata'
)
then
'保量卡片'
when
params
[
'transaction_type'
]
in
(
'samecity_ctr'
)
then
'samecity_ctr'
when
params
[
'transaction_type'
]
in
(
'samecity_cvr'
,
'samecity_ctcvr'
)
then
'samecity_cvr'
when
params
[
'transaction_type'
]
in
(
'hotspot_feed'
)
then
'hotspot_feed'
END
,
when
params
[
'transaction_type'
]
in
(
'hotspot_feed'
)
then
'hotspot_feed'
when
params
[
'transaction_type'
]
in
(
'fmctr'
)
then
'fmctr'
END
,
params
[
'card_id'
],
app_session_id
)
a
...
...
pm/kyc_q2/job/step2.job
View file @
f219b157
#step2.job
type=command
dependencies=step1_1,step1_2,step1_3,step1_4,step1_5,step1_6,step1_7,step1_8,step1_9,step1_10,step1_11,step1_12,step1_13,step1_14,step1_15,step1_16,step1_17,step1_18,step1_19,step1_20,step1_21
command=curl -X GET http://localhost:8553/api/report/email/kyc_q2/weiyimin@igengmei.com/weiyimin@qq.com
\ No newline at end of file
command=curl -X GET http://localhost:8553/api/report/email/kyc_q2/weiyimin@igengmei.com/weiyimin@qq.com
pm/kyc_q2/report/ai_daily.sql
View file @
f219b157
SET
mapreduce
.
job
.
queuename
=
data
;
set
role
admin
;
ADD
JAR
hdfs
:
///
user
/
hive
/
share
/
lib
/
udf
/
hive
-
udf
-
1
.
0
-
SNAPSHOT
.
jar
;
CREATE
TEMPORARY
FUNCTION
convup
AS
'com.gmei.hive.common.udf.UDFConvUpgrade'
;
CREATE
TEMPORARY
FUNCTION
setencryption
AS
'com.gmei.hive.common.udf.UDFStringSetEncryption'
;
...
...
pm/kyc_q2/report/ai_qa.sql
View file @
f219b157
SET
mapreduce
.
job
.
queuename
=
data
;
set
role
admin
;
ADD
JAR
hdfs
:
///
user
/
hive
/
share
/
lib
/
udf
/
hive
-
udf
-
1
.
0
-
SNAPSHOT
.
jar
;
CREATE
TEMPORARY
FUNCTION
convup
AS
'com.gmei.hive.common.udf.UDFConvUpgrade'
;
--进制转换函数,支持各种进制转换
CREATE
TEMPORARY
FUNCTION
setencryption
AS
'com.gmei.hive.common.udf.UDFStringSetEncryption'
;
...
...
pm/kyc_q2/report/kyc_qa_daily.sql
View file @
f219b157
SET
mapreduce
.
job
.
queuename
=
data
;
set
role
admin
;
ADD
JAR
hdfs
:
///
user
/
hive
/
share
/
lib
/
udf
/
hive
-
udf
-
1
.
0
-
SNAPSHOT
.
jar
;
CREATE
TEMPORARY
FUNCTION
convup
AS
'com.gmei.hive.common.udf.UDFConvUpgrade'
;
CREATE
TEMPORARY
FUNCTION
setencryption
AS
'com.gmei.hive.common.udf.UDFStringSetEncryption'
;
...
...
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