Hi , ive put together a database that records when a user has viewed a safety message for the day and also the ability to update the database if they miss a day by using an update form. What ive been trying to do is have the user notified on logging in that they have missed a day on a certain week.
I don't need to alert the user to a particular day just to the fact a day is missed. What ive been trying to do is run a query that checks the username against a table containing the username and 5 yes/no fields one for each day and a weekno, so for example if they missed tuesday on week 32 it would set a flag and the user would be alerted.
As above this creates a field if a field is empty, ive tried to use count to count any values created in the expr fields, all i care about is being able to run the query and somehow get a flag a day has been missed. i cant seem to think how to get a false detected using COUNT or with an OR function if any expr field has data
Could someone please point in the right direction with some suggestions if this is makes any sense....
thanks
ian
I don't need to alert the user to a particular day just to the fact a day is missed. What ive been trying to do is run a query that checks the username against a table containing the username and 5 yes/no fields one for each day and a weekno, so for example if they missed tuesday on week 32 it would set a flag and the user would be alerted.
SELECT tbl_login.UserName, tbl_login.mon, IIf([mon]=0," monfalse,","") AS Expr1, tbl_login.tue, IIf([tue]=0," tuefalse,","") AS Expr2, tbl_login.wed, IIf([wed]=0," wedfalse,","") AS Expr3, tbl_login.thu, IIf([thu]=0," thufalse,","") AS Expr4, tbl_login.fri, IIf([fri]=0," frifalse,","") AS Expr5, tbl_login.weekno
FROM tbl_login
WHERE (((tbl_login.UserName)="bs"));
As above this creates a field if a field is empty, ive tried to use count to count any values created in the expr fields, all i care about is being able to run the query and somehow get a flag a day has been missed. i cant seem to think how to get a false detected using COUNT or with an OR function if any expr field has data
Could someone please point in the right direction with some suggestions if this is makes any sense....
thanks
ian