舆情函数调通

This commit is contained in:
juanboy
2024-07-04 12:34:35 +08:00
parent e43615d5aa
commit 70e82a2c29
2 changed files with 9 additions and 7 deletions
+8 -5
View File
@@ -43,7 +43,8 @@ def topicdefine():
return label_article,label_comments
# 更新数据库
def update_data(label_article,label_comments):
def update_data():
label_article,label_comments=topicdefine()
add_label_comments()
add_label_article()
for row in label_article:
@@ -57,7 +58,9 @@ def update_data(label_article,label_comments):
params = [str(label),str(id)]
query(sql, params)
# x,y=topicdefine()
# update_data(x,y)
drop_label()
drop_label1()
if __name__ == '__main__':
update_data()
#删除文章和评论的标签列
# drop_label()
# drop_label1()
+1 -2
View File
@@ -40,5 +40,4 @@ def clean(text):
return text.strip()
if __name__ == '__main__':
writer_comments_cuts()
# print(clean("想到一次我也看到了这样的,我把我的外套(喷了淡茉莉香水的)递过去了,我当时觉得她可能是因为地铁空调有点冷一直环抱着,我借给她说冷的话可以披一下,我坐到终点站的,然后她说不用了,我好尴尬哇"))
writer_comments_cuts()