Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
Amazon-Selection-Data
Overview
Overview
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
abel_cjy
Amazon-Selection-Data
Commits
be5e8a3c
Commit
be5e8a3c
authored
Jul 13, 2026
by
hejiangming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
no message
parent
d788f619
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
8 deletions
+13
-8
dws_aba_word_freq_cate.py
Pyspark_job/sqoop_export/dws_aba_word_freq_cate.py
+13
-8
No files found.
Pyspark_job/sqoop_export/dws_aba_word_freq_cate.py
View file @
be5e8a3c
...
...
@@ -173,14 +173,19 @@ if __name__ == '__main__':
# 10) 往流程看板表 workflow_everyday 写记录
# CommonUtil.modify_export_workflow_status: 是给"一个 page(页面) 由多个导出脚本共同产出"的场景用的——要等同组脚本全部完成才点亮看板。
# 分类词频这个 page 只有本脚本一个导出源(belonging_to_process=分类词频_month 组内独一份), 就直连
update_workflow_sql
=
f
"""
REPLACE INTO selection.workflow_everyday
(site_name, report_date, status, status_val, table_name, date_type, page, is_end, remark, export_db_type, freeze_flag)
VALUES('{site_name}', '{date_info}', '导出PG数据库完成', 14, '{export_base_tb}', '{date_type}', '分类词频', '是', '分类词频数据', '{db_type}', NULL);
"""
mysql_engine
=
DBUtil
.
get_db_engine
(
'mysql'
,
'us'
)
DBUtil
.
engine_exec_sql
(
mysql_engine
,
update_workflow_sql
)
mysql_engine
.
dispose
()
# 只有 2025-07(含)以后的正式月份才写记录表。
# date_info 是 'YYYY-MM' 格式,这种定长格式直接用字符串比较大小即正确,无需转日期。
if
date_info
>=
'2025-07'
:
update_workflow_sql
=
f
"""
REPLACE INTO selection.workflow_everyday
(site_name, report_date, status, status_val, table_name, date_type, page, is_end, remark, export_db_type, freeze_flag)
VALUES('{site_name}', '{date_info}', '导出PG数据库完成', 14, '{export_base_tb}', '{date_type}', '分类词频', '是', '分类词频数据', '{db_type}', NULL);
"""
mysql_engine
=
DBUtil
.
get_db_engine
(
'mysql'
,
'us'
)
DBUtil
.
engine_exec_sql
(
mysql_engine
,
update_workflow_sql
)
mysql_engine
.
dispose
()
else
:
print
(
f
"[SKIP] date_info={date_info} 早于 2025-07,为历史回刷数据,跳过写入 workflow_everyday 记录表"
)
print
(
f
"==================表 {export_table} 导出完成=================================="
)
print
(
"success"
)
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