From f447a807b255b6e4983c4b24bffd75542a10b104 Mon Sep 17 00:00:00 2001 From: W1CDN Date: Wed, 12 Jul 2023 13:36:27 -0500 Subject: [PATCH] Gotta update the datestamp too. --- kiss_and_db.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/kiss_and_db.py b/kiss_and_db.py index 81c43f7..4999e99 100644 --- a/kiss_and_db.py +++ b/kiss_and_db.py @@ -84,7 +84,8 @@ def main(): query3 = "INSERT INTO stations ([from], last_heard_unix, count) \ VALUES("+station_update+") \ ON CONFLICT([from]) \ - DO UPDATE SET count = count + 1;" + DO UPDATE SET count = count + 1,\ + last_heard_unix = excluded.last_heard_unix;" #print(query3) logging.debug(query3) # Insert/update data