diff --git a/DataCenter_Windows/WindowsDataCenter/SQLiteRepository/SQLiteProcedures.cs b/DataCenter_Windows/WindowsDataCenter/SQLiteRepository/SQLiteProcedures.cs index 56611d7..b7c9754 100644 --- a/DataCenter_Windows/WindowsDataCenter/SQLiteRepository/SQLiteProcedures.cs +++ b/DataCenter_Windows/WindowsDataCenter/SQLiteRepository/SQLiteProcedures.cs @@ -8,7 +8,7 @@ namespace SQLiteRepository internal static class SQLiteProcedures { public const string GET_LOGS_IN_LAST_X_MINUTES = - "select * from TimeLogDb where " + nameof(TimeLogDb.SwipeEventDateTime) + " > ? AND " + + "select * from " + nameof(TimeLogDb) + " where " + nameof(TimeLogDb.SwipeEventDateTime) + " > ? AND " + nameof(TimeLogDb.UserId_FK) + "=?"; public const string GET_TIMELOGS = @@ -108,7 +108,7 @@ namespace SQLiteRepository "on ujdb." + nameof(UserGroupJoinDb.GroupId_FK) + " = gp." + nameof(GroupDb.GroupId) + " group by gp." + nameof(GroupDb.GroupId); - public const string GET_GROUPS_FOR_USER = "select gdb." + nameof(GroupDb.GroupId) + ", gdb." + nameof(GroupDb.GroupName) + ", gdb.AssignedUserCount" + + public const string GET_GROUPS_FOR_USER = "select gdb." + nameof(GroupDb.GroupId) + ", gdb." + nameof(GroupDb.GroupName) + ", gdb." + nameof(GroupDb.AssignedUserCount) + "" + " from " + nameof(GroupDb) + " gdb" + " left join " + nameof(UserGroupJoinDb) + " ujdb" + " on gdb." + nameof(GroupDb.GroupId) + " = ujdb." + nameof(UserGroupJoinDb.GroupId_FK) + @@ -141,7 +141,7 @@ namespace SQLiteRepository + nameof(TimeLogDb.Source) + "=? " + "where " + nameof(TimeLogDb.Id) + "=?"; - public const string GET_DB_VERSION = "select * from DbVersion"; + public const string GET_DB_VERSION = "select * from " + nameof(DbVersion); /// /// This works on the tokenisation of the query string.