From 1728ef46909b4a3cb854c6f4d60fb19af4d8a31e Mon Sep 17 00:00:00 2001 From: BroodjeAap Date: Mon, 23 Nov 2020 17:33:31 +0100 Subject: [PATCH] Fixed answer db views, seperate name for generated time in seconds --- lib/pages/practice/PracticeDatabase.dart | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/pages/practice/PracticeDatabase.dart b/lib/pages/practice/PracticeDatabase.dart index fa6437c..3444f14 100644 --- a/lib/pages/practice/PracticeDatabase.dart +++ b/lib/pages/practice/PracticeDatabase.dart @@ -62,7 +62,7 @@ class PracticeDatabase { CAST( strftime('%s', time) AS INTEGER - ) as time, + ) as s_time, CAST( strftime("%s", DATETIME('now', '-7 day')) AS INTEGER @@ -70,7 +70,7 @@ class PracticeDatabase { FROM AnswersView WHERE - time > before + s_time > before GROUP BY type; '''); @@ -84,7 +84,7 @@ class PracticeDatabase { CAST( strftime('%s', time) AS INTEGER - ) as time, + ) as s_time, CAST( strftime("%s", DATETIME('now', '-1 month')) AS INTEGER @@ -92,7 +92,7 @@ class PracticeDatabase { FROM AnswersView WHERE - time > before + s_time > before GROUP BY type; ''');