Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
F
ffm-baseline
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ML
ffm-baseline
Commits
cb3dc8ba
Commit
cb3dc8ba
authored
Dec 28, 2018
by
王志伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
smart_rank 相关的统计指标
parent
5becc769
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
5 deletions
+20
-5
temp_analysis.scala
eda/feededa/src/main/scala/com/gmei/temp_analysis.scala
+20
-5
No files found.
eda/feededa/src/main/scala/com/gmei/temp_analysis.scala
View file @
cb3dc8ba
...
@@ -615,17 +615,32 @@ object smart_rank_count {
...
@@ -615,17 +615,32 @@ object smart_rank_count {
final_id
.
createOrReplaceTempView
(
"final_id"
)
final_id
.
createOrReplaceTempView
(
"final_id"
)
val
meigou_pv
=
sc
.
sql
(
val
user_city_meigou
=
sc
.
sql
(
s
"""
s
"""
|select
device,params
|select
cl_id,city_id,params['business_id'] as meigou_id
|from online.tl_hdfs_maidian_view
|from online.tl_hdfs_maidian_view
|where action = "page_view"
|where action = "page_view"
|and params['page_name']="welfare_detail"
|and params['page_name']="welfare_detail"
|and partition_date ='20181201'
|and partition_date
>
='20181201'
|
LIMIT 3
|
and city_id is not null
"""
.
stripMargin
"""
.
stripMargin
)
)
meigou_pv
.
show
(
80
)
user_city_meigou
.
show
(
80
)
val
meigou_city
=
sc
.
sql
(
s
"""
|select b.id as meigou_id,d.city_id as meigou_city
|from online.tl_meigou_service_view b
|left join online.tl_hdfs_doctor_view c on b.doctor_id=c.id
|left join online.tl_hdfs_hospital_view d on c.hospital_id=d.id
|where b.partition_date='20181227'
|and c.partition_date='20181227'
|and d.partition_date='20181227'
"""
.
stripMargin
)
meigou_city
.
show
()
// val zixun_pv = sc.sql(
// val zixun_pv = sc.sql(
// s"""
// s"""
...
...
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