From 5a1684189e7110fb6aaf8ba2faf1c16c8c6a8566 Mon Sep 17 00:00:00 2001 From: sgoudham Date: Thu, 9 Jul 2020 21:02:49 +0100 Subject: [PATCH] Committing Database Transaction --- main.py | 1 + 1 file changed, 1 insertion(+) diff --git a/main.py b/main.py index c38d922b..fabfd10a 100644 --- a/main.py +++ b/main.py @@ -71,6 +71,7 @@ async def on_message(message): cursor = conn.cursor() # Execute the SQL Query cursor.execute(insert_query, val) + conn.commit() print(cursor.rowcount, "Record inserted successfully into Logs") except mariadb.Error as ex: