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
5c874590
Commit
5c874590
authored
Jun 22, 2020
by
魏艺敏
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update codes
parent
d94caf39
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
195 additions
and
175 deletions
+195
-175
meigou_detail_page_dispense_pv.sql
...bak/meigou_detail_page/meigou_detail_page_dispense_pv.sql
+24
-24
meigou_detail_page_dispense_uv.sql
...bak/meigou_detail_page/meigou_detail_page_dispense_uv.sql
+155
-135
meigou_detail_page_source_pv.sql
sqls/bak/meigou_detail_page/meigou_detail_page_source_pv.sql
+8
-8
meigou_detail_page_source_uv.sql
sqls/bak/meigou_detail_page/meigou_detail_page_source_uv.sql
+8
-8
No files found.
sqls/bak/meigou_detail_page/meigou_detail_page_dispense_pv.sql
View file @
5c874590
...
...
@@ -64,8 +64,8 @@ FROM
(
SELECT
partition_date
,
cl_id
,
'美购详情页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
((
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'page_view'
)
pv
...
...
@@ -88,8 +88,8 @@ FROM
SELECT
partition_date
,
cl_id
,
'加购物车'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
((
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'welfare_multiattribute_click_add'
...
...
@@ -97,8 +97,8 @@ FROM
SELECT
partition_date
,
cl_id
,
'右上角购物车'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
((
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_navbar_cart'
...
...
@@ -106,7 +106,7 @@ FROM
--点击查看更多评论
SELECT
partition_date
,
cl_id
,
'评价列表页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_comment'
...
...
@@ -115,7 +115,7 @@ FROM
--点击外显的评价标签
SELECT
partition_date
,
cl_id
,
'评价列表页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'service_comment_click_tag'
...
...
@@ -124,7 +124,7 @@ FROM
--点击外显的日记卡片
SELECT
partition_date
,
cl_id
,
'评价列表页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'welfare_detail_comment_click_diary_card'
...
...
@@ -133,7 +133,7 @@ FROM
SELECT
partition_date
,
cl_id
,
'立即支付'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'welfare_multiattribute_click_buy'
...
...
@@ -142,7 +142,7 @@ FROM
--点击选择更美项目
SELECT
partition_date
,
cl_id
,
'选择美购项目'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
...
...
@@ -152,7 +152,7 @@ FROM
--7.22新版本--点击外露的美购项目
SELECT
partition_date
,
cl_id
,
'选择美购项目'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
...
...
@@ -162,7 +162,7 @@ FROM
--7.22新版本--点击查看更多
SELECT
partition_date
,
cl_id
,
'选择美购项目'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
...
...
@@ -172,7 +172,7 @@ FROM
--点击私信按钮
SELECT
partition_date
,
cl_id
,
'私信及电话咨询'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_message'
...
...
@@ -181,7 +181,7 @@ FROM
--7.20之后灰度上线的快捷咨询按钮和预约面诊按钮
SELECT
partition_date
,
cl_id
,
'私信及电话咨询'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
...
...
@@ -191,7 +191,7 @@ FROM
--点击机构下面的在线咨询和电话咨询
SELECT
partition_date
,
cl_id
,
'私信及电话咨询'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_curearea_contact'
...
...
@@ -201,7 +201,7 @@ FROM
SELECT
partition_date
,
cl_id
,
'机构主页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_curearea'
...
...
@@ -211,7 +211,7 @@ FROM
SELECT
partition_date
,
cl_id
,
'机构的其他美购'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_seller_service_item'
...
...
@@ -220,7 +220,7 @@ FROM
SELECT
partition_date
,
cl_id
,
'机构导航'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_address'
...
...
@@ -229,7 +229,7 @@ FROM
SELECT
partition_date
,
cl_id
,
'推荐美购'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_card'
...
...
@@ -240,7 +240,7 @@ FROM
SELECT
partition_date
,
cl_id
,
'收藏'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_favor'
...
...
@@ -251,7 +251,7 @@ FROM
SELECT
partition_date
,
cl_id
,
'医生主页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_curearea'
...
...
@@ -261,7 +261,7 @@ FROM
SELECT
partition_date
,
cl_id
,
'分享'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'page_click_share'
...
...
@@ -289,7 +289,7 @@ FROM
FROM
al
.
al_pm_ct_dv_deviceappversionrollbackfrom20200101_d
WHERE
partition_day
=
regexp_replace
(
DATE_SUB
(
current_date
,
2
)
,
'-'
,
''
))
a
ON
m
.
device_id
=
a
.
device_id
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
6
0
)
,
'-'
,
''
)
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
9
0
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
active_type
in
(
'1'
,
'2'
,
'4'
)
and
first_channel_source_type
not
in
(
'yqxiu1'
,
'yqxiu2'
,
'yqxiu3'
,
'yqxiu4'
,
'yqxiu5'
,
'mxyc1'
,
'mxyc2'
,
'mxyc3'
...
...
sqls/bak/meigou_detail_page/meigou_detail_page_dispense_uv.sql
View file @
5c874590
...
...
@@ -58,7 +58,8 @@ FROM
(
SELECT
partition_date
,
cl_id
,
'美购详情页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'page_view'
)
pv
...
...
@@ -79,166 +80,185 @@ FROM
UNION
ALL
SELECT
partition_date
,
cl_id
,
'加购物车'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'welfare_multiattribute_click_add'
SELECT
partition_date
,
cl_id
,
'加购物车'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'welfare_multiattribute_click_add'
UNION
ALL
UNION
ALL
SELECT
partition_date
,
cl_id
,
'右上角购物车'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_navbar_cart'
SELECT
partition_date
,
cl_id
,
'右上角购物车'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_navbar_cart'
UNION
ALL
--点击查看更多评论
SELECT
partition_date
,
cl_id
,
'评价列表页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_comment'
UNION
ALL
--点击查看更多评论
SELECT
partition_date
,
cl_id
,
'评价列表页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_comment'
UNION
ALL
--点击外显的评价标签
SELECT
partition_date
,
cl_id
,
'评价列表页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'service_comment_click_tag'
UNION
ALL
--点击外显的评价标签
SELECT
partition_date
,
cl_id
,
'评价列表页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'service_comment_click_tag'
UNION
ALL
--点击外显的日记卡片
SELECT
partition_date
,
cl_id
,
'评价列表页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'welfare_detail_comment_click_diary_card'
UNION
ALL
--点击外显的日记卡片
SELECT
partition_date
,
cl_id
,
'评价列表页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'welfare_detail_comment_click_diary_card'
UNION
ALL
UNION
ALL
SELECT
partition_date
,
cl_id
,
'立即支付'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'welfare_multiattribute_click_buy'
SELECT
partition_date
,
cl_id
,
'立即支付'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'welfare_multiattribute_click_buy'
UNION
ALL
--点击选择更美项目
SELECT
partition_date
,
cl_id
,
'选择美购项目'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
AND
params
[
'button_name'
]
=
'sku_choose'
UNION
ALL
--点击选择更美项目
SELECT
partition_date
,
cl_id
,
'选择美购项目'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
AND
params
[
'button_name'
]
=
'sku_choose'
UNION
ALL
--7.22新版本--点击外露的美购项目
SELECT
partition_date
,
cl_id
,
'选择美购项目'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
AND
params
[
'button_name'
]
=
'service_sku'
UNION
ALL
--7.22新版本--点击外露的美购项目
SELECT
partition_date
,
cl_id
,
'选择美购项目'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
AND
params
[
'button_name'
]
=
'service_sku'
UNION
ALL
--7.22新版本--点击查看更多
SELECT
partition_date
,
cl_id
,
'选择美购项目'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
AND
params
[
'button_name'
]
=
'sku_all'
UNION
ALL
--7.22新版本--点击查看更多
SELECT
partition_date
,
cl_id
,
'选择美购项目'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
AND
params
[
'button_name'
]
=
'sku_all'
UNION
ALL
--点击私信按钮
SELECT
partition_date
,
cl_id
,
'私信及电话咨询'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_message'
UNION
ALL
--点击私信按钮
SELECT
partition_date
,
cl_id
,
'私信及电话咨询'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_message'
UNION
ALL
--7.20之后灰度上线的快捷咨询按钮和预约面诊按钮
SELECT
partition_date
,
cl_id
,
'私信及电话咨询'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
AND
params
[
'button_name'
]
in
(
'question_tag'
,
'appointment'
)
UNION
ALL
--7.20之后灰度上线的快捷咨询按钮和预约面诊按钮
SELECT
partition_date
,
cl_id
,
'私信及电话咨询'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
AND
params
[
'button_name'
]
in
(
'question_tag'
,
'appointment'
)
UNION
ALL
--点击机构下面的在线咨询和电话咨询
SELECT
partition_date
,
cl_id
,
'私信及电话咨询'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_curearea_contact'
AND
params
[
'connect_type'
]
in
(
'onlineconsult'
,
'phone'
)
UNION
ALL
--点击机构下面的在线咨询和电话咨询
SELECT
partition_date
,
cl_id
,
'私信及电话咨询'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_curearea_contact'
AND
params
[
'connect_type'
]
in
(
'onlineconsult'
,
'phone'
)
UNION
ALL
UNION
ALL
SELECT
partition_date
,
cl_id
,
'机构主页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_curearea'
AND
params
[
'cure_type'
]
=
'organization'
SELECT
partition_date
,
cl_id
,
'机构主页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_curearea'
AND
params
[
'cure_type'
]
=
'organization'
UNION
ALL
UNION
ALL
SELECT
partition_date
,
cl_id
,
'机构的其他美购'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_seller_service_item'
SELECT
partition_date
,
cl_id
,
'机构的其他美购'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_seller_service_item'
UNION
ALL
UNION
ALL
SELECT
partition_date
,
cl_id
,
'机构导航'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_address'
SELECT
partition_date
,
cl_id
,
'机构导航'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_address'
UNION
ALL
UNION
ALL
SELECT
partition_date
,
cl_id
,
'推荐美购'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_card'
AND
params
[
'card_content_type'
]
=
'service'
AND
params
[
'tab_name'
]
=
'推荐'
SELECT
partition_date
,
cl_id
,
'推荐美购'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_card'
AND
params
[
'card_content_type'
]
=
'service'
AND
params
[
'tab_name'
]
=
'推荐'
UNION
ALL
UNION
ALL
SELECT
partition_date
,
cl_id
,
'收藏'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_favor'
AND
params
[
'favor_type'
]
=
'service'
AND
params
[
'motion'
]
=
'do'
SELECT
partition_date
,
cl_id
,
'收藏'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_favor'
AND
params
[
'favor_type'
]
=
'service'
AND
params
[
'motion'
]
=
'do'
UNION
ALL
UNION
ALL
SELECT
partition_date
,
cl_id
,
'医生主页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_curearea'
AND
params
[
'cure_type'
]
=
'doctor'
SELECT
partition_date
,
cl_id
,
'医生主页'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_curearea'
AND
params
[
'cure_type'
]
=
'doctor'
UNION
ALL
UNION
ALL
SELECT
partition_date
,
cl_id
,
'分享'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
'20191201'
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'page_click_share'
SELECT
partition_date
,
cl_id
,
'分享'
as
type
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'page_click_share'
)
click
JOIN
(
...
...
@@ -263,7 +283,7 @@ FROM
FROM
al
.
al_pm_ct_dv_deviceappversionrollbackfrom20200101_d
WHERE
partition_day
=
regexp_replace
(
DATE_SUB
(
current_date
,
2
)
,
'-'
,
''
))
a
ON
m
.
device_id
=
a
.
device_id
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
6
0
)
,
'-'
,
''
)
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
9
0
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
active_type
in
(
'1'
,
'2'
,
'4'
)
and
first_channel_source_type
not
in
(
'yqxiu1'
,
'yqxiu2'
,
'yqxiu3'
,
'yqxiu4'
,
'yqxiu5'
,
'mxyc1'
,
'mxyc2'
,
'mxyc3'
...
...
sqls/bak/meigou_detail_page/meigou_detail_page_source_pv.sql
View file @
5c874590
...
...
@@ -199,7 +199,7 @@ FROM
(
SELECT
partition_date
,
page_name
,
cl_id
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'page_view'
...
...
@@ -227,7 +227,7 @@ FROM
FROM
al
.
al_pm_ct_dv_deviceappversionrollbackfrom20200101_d
WHERE
partition_day
=
regexp_replace
(
DATE_SUB
(
current_date
,
2
)
,
'-'
,
''
))
a
ON
m
.
device_id
=
a
.
device_id
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
6
0
)
,
'-'
,
''
)
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
9
0
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
active_type
in
(
'1'
,
'2'
,
'4'
)
and
first_channel_source_type
not
in
(
'yqxiu1'
,
'yqxiu2'
,
'yqxiu3'
,
'yqxiu4'
,
'yqxiu5'
,
'mxyc1'
,
'mxyc2'
,
'mxyc3'
...
...
@@ -288,7 +288,7 @@ FROM
(
SELECT
partition_date
,
referrer
,
cl_id
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'page_view'
...
...
@@ -316,7 +316,7 @@ FROM
FROM
al
.
al_pm_ct_dv_deviceappversionrollbackfrom20200101_d
WHERE
partition_day
=
regexp_replace
(
DATE_SUB
(
current_date
,
2
)
,
'-'
,
''
))
a
ON
m
.
device_id
=
a
.
device_id
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
6
0
)
,
'-'
,
''
)
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
9
0
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
active_type
in
(
'1'
,
'2'
,
'4'
)
and
first_channel_source_type
not
in
(
'yqxiu1'
,
'yqxiu2'
,
'yqxiu3'
,
'yqxiu4'
,
'yqxiu5'
,
'mxyc1'
,
'mxyc2'
,
'mxyc3'
...
...
@@ -414,7 +414,7 @@ FROM
(
--点击加车/支付
SELECT
partition_date
,
referrer
,
action
,
cl_id
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
in
(
'welfare_multiattribute_click_add'
,
'welfare_multiattribute_click_buy'
)
...
...
@@ -423,7 +423,7 @@ FROM
--点击私信按钮
SELECT
partition_date
,
referrer
,
action
,
cl_id
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_message'
...
...
@@ -439,7 +439,7 @@ FROM
(
SELECT
partition_date
,
params
[
'referrer_link'
]
as
referrer_link
,
cl_id
,
action
,
json_split
(
params
[
'referrer_link'
],
'string'
)
as
a
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
...
...
@@ -473,7 +473,7 @@ FROM
FROM
al
.
al_pm_ct_dv_deviceappversionrollbackfrom20200101_d
WHERE
partition_day
=
regexp_replace
(
DATE_SUB
(
current_date
,
2
)
,
'-'
,
''
))
a
ON
m
.
device_id
=
a
.
device_id
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
6
0
)
,
'-'
,
''
)
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
9
0
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
active_type
in
(
'1'
,
'2'
,
'4'
)
and
first_channel_source_type
not
in
(
'yqxiu1'
,
'yqxiu2'
,
'yqxiu3'
,
'yqxiu4'
,
'yqxiu5'
,
'mxyc1'
,
'mxyc2'
,
'mxyc3'
...
...
sqls/bak/meigou_detail_page/meigou_detail_page_source_uv.sql
View file @
5c874590
...
...
@@ -193,7 +193,7 @@ FROM
(
SELECT
partition_date
,
page_name
,
cl_id
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'page_view'
...
...
@@ -221,7 +221,7 @@ FROM
FROM
al
.
al_pm_ct_dv_deviceappversionrollbackfrom20200101_d
WHERE
partition_day
=
regexp_replace
(
DATE_SUB
(
current_date
,
2
)
,
'-'
,
''
))
a
ON
m
.
device_id
=
a
.
device_id
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
6
0
)
,
'-'
,
''
)
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
9
0
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
active_type
in
(
'1'
,
'2'
,
'4'
)
and
first_channel_source_type
not
in
(
'yqxiu1'
,
'yqxiu2'
,
'yqxiu3'
,
'yqxiu4'
,
'yqxiu5'
,
'mxyc1'
,
'mxyc2'
,
'mxyc3'
...
...
@@ -282,7 +282,7 @@ FROM
(
SELECT
partition_date
,
referrer
,
cl_id
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'page_view'
...
...
@@ -310,7 +310,7 @@ FROM
FROM
al
.
al_pm_ct_dv_deviceappversionrollbackfrom20200101_d
WHERE
partition_day
=
regexp_replace
(
DATE_SUB
(
current_date
,
2
)
,
'-'
,
''
))
a
ON
m
.
device_id
=
a
.
device_id
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
6
0
)
,
'-'
,
''
)
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
9
0
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
active_type
in
(
'1'
,
'2'
,
'4'
)
and
first_channel_source_type
not
in
(
'yqxiu1'
,
'yqxiu2'
,
'yqxiu3'
,
'yqxiu4'
,
'yqxiu5'
,
'mxyc1'
,
'mxyc2'
,
'mxyc3'
...
...
@@ -408,7 +408,7 @@ FROM
(
--点击加车/支付
SELECT
partition_date
,
referrer
,
action
,
cl_id
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
in
(
'welfare_multiattribute_click_add'
,
'welfare_multiattribute_click_buy'
)
...
...
@@ -417,7 +417,7 @@ FROM
--点击私信按钮
SELECT
partition_date
,
referrer
,
action
,
cl_id
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
--AND page_name = 'welfare_detail'
AND
action
=
'welfare_detail_click_message'
...
...
@@ -433,7 +433,7 @@ FROM
(
SELECT
partition_date
,
params
[
'referrer_link'
]
as
referrer_link
,
cl_id
,
action
,
json_split
(
params
[
'referrer_link'
],
'string'
)
as
a
FROM
online
.
bl_hdfs_maidian_updates
WHERE
partition_date
>=
regexp_replace
(
(
current_date
-
interval
'90'
day
)
,
'-'
,
''
)
WHERE
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
90
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
page_name
=
'welfare_detail'
AND
action
=
'on_click_button'
...
...
@@ -467,7 +467,7 @@ FROM
FROM
al
.
al_pm_ct_dv_deviceappversionrollbackfrom20200101_d
WHERE
partition_day
=
regexp_replace
(
DATE_SUB
(
current_date
,
2
)
,
'-'
,
''
))
a
ON
m
.
device_id
=
a
.
device_id
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
6
0
)
,
'-'
,
''
)
where
partition_date
>=
regexp_replace
(
DATE_SUB
(
current_date
,
9
0
)
,
'-'
,
''
)
AND
partition_date
<
regexp_replace
((
current_date
),
'-'
,
''
)
AND
active_type
in
(
'1'
,
'2'
,
'4'
)
and
first_channel_source_type
not
in
(
'yqxiu1'
,
'yqxiu2'
,
'yqxiu3'
,
'yqxiu4'
,
'yqxiu5'
,
'mxyc1'
,
'mxyc2'
,
'mxyc3'
...
...
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