From ba93e68976a80520716bb6e9785062f35806d0f4 Mon Sep 17 00:00:00 2001 From: liuwei Date: Sat, 8 Feb 2025 10:25:02 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=8D=E4=BD=BF=E7=94=A8=E6=9C=AC=E5=9C=B0?= =?UTF-8?q?=E5=BA=93=EF=BC=8C=E4=BD=BF=E7=94=A8mariadb=E5=AE=8C=E6=88=90?= =?UTF-8?q?=E5=AD=98=E5=82=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- message_report/write_db.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/message_report/write_db.py b/message_report/write_db.py index 7188b5f..0830276 100644 --- a/message_report/write_db.py +++ b/message_report/write_db.py @@ -55,7 +55,7 @@ def generate_and_send_ranking(groupId, allContacts: dict): query = """ SELECT wx_id, count AS speech_count FROM speech_counts - WHERE DATE(date) = DATE('now', '-1 day') + WHERE DDATE_FORMAT(DATE_SUB('2025-01-01', INTERVAL 1 DAY), '%Y-%m-%d') AND group_id = %s GROUP BY wx_id ORDER BY count DESC