I have the following query but I can't seem to figure one thing out. I have a table (Employees) with items in it such as Name, Shift, Line, Etc as well as a calendar of sorts indicating if the employee is working or not.
One table row looks like this
32 John Baker 5 A SS O O (Null) (Null) (Null) (Null)
ID FirstName LastName Line Shift Discipline APR1_2300 APR1_0300 Apr2_2300 APR2_0300 APR3_2300 APR3_0300
The dates continue on to the end of the year
The dates indicate the month day of the month and time for instance APR1_2300 is April 1st 11pm
How can I modify the query so that it will ask me for a specific day? I want the query to tell me which names have a Null value because that indicates they are working that day and thus will generate on the report. From the above example I want to see all of the Null and WSW" values from 2 columns APR1_2300 and APR1_0300. The query below does that for me I understand however I don't want to write 365 queries one for each day of the year that is why I want it to ask me for the date(s) I am looking for.
SELECT Employees.ID, Employees.FIRSTNAME, Employees.LASTNAME, Employees.SHIFT, Employees.LINE, Employees.MONTH, Employees.DISIPLINE, Employees.APR1_2300, Employees.APR1_0300
FROM Employees
WHERE (((Employees.APR1_2300) Is Null Or (Employees.APR1_2300)="wsw")) OR (((Employees.APR1_0300) Is Null Or (Employees.APR1_0300)="wsw"))
ORDER BY Employees.DISIPLINE;
Thanks for any and all help.