From a5c16b88c9061663475e83344adb818659dd6b75 Mon Sep 17 00:00:00 2001 From: KevinMidboe Date: Fri, 10 Feb 2017 16:44:43 +0100 Subject: [PATCH] Changed so that time added to db only has two decimal points. --- macLookup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/macLookup.py b/macLookup.py index 620b895..207ae94 100755 --- a/macLookup.py +++ b/macLookup.py @@ -65,7 +65,7 @@ def updateTimes(): online = list(set(getOnlineClients()) & set(getAddr(c))) for adr in online: - c.execute('UPDATE lastonline SET timesince='+ str(curTime) +' WHERE clientadr="'+ adr + '"') + c.execute('UPDATE lastonline SET timesince='+ str("{:10.2f}".format(curTime)) +' WHERE clientadr="'+ adr + '"') conn.commit() conn.close()