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
ed7c6985
Commit
ed7c6985
authored
Dec 25, 2018
by
高雅喆
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add device_search_tag
parent
6b98b64d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
EsmmData.scala
eda/feededa/src/main/scala/com/gmei/EsmmData.scala
+7
-2
No files found.
eda/feededa/src/main/scala/com/gmei/EsmmData.scala
View file @
ed7c6985
...
...
@@ -567,12 +567,17 @@ object GetDevicePortrait {
device_search_tag
.
createOrReplaceTempView
(
"tag_count"
)
val
max_count_tag
_
=
sc
.
sql
(
val
max_count_tag
=
sc
.
sql
(
s
"""
|select a.device_id,a.stat_date,a.cid_id,a.level1_count
|from
|from tag_count a
|inner join
|(select device_id,max(level1_count) as max_count from tag_count group by device_id) b
|on a.level1_count = b.max_count and a.device_id = b.device_id
"""
.
stripMargin
)
max_count_tag
.
show
()
println
(
max_count_tag
.
count
())
// GmeiConfig.writeToJDBCTable(diary_tag,"diary_feat",SaveMode.Overwrite)
...
...
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