Actually it is part of q select query where if I get a true response, I want to alter the variable and increase the duration. I intend to get to that next week. For now, I did figure out that I can use PARAMETERS to set thi up, at least I think so. I tried this:
PARAMETERS [RptDur] Integer;
Then I added this:
WHERE ([RptDur]=-14)
I get a pop-up window, which I don't want, but if I enter the -14, I get the correct results. So my question is how can I set a default? Thank you for your response.
Yhe whole query gets a little long so I think I'll just do the top part:
PARAMETERS [RptDur] Long;
SELECT Att.EmployeeNumber,
Emp.NameFirst, Emp.NameInitial,
Emp.NameLast,
COUNT(Att.EmployeeNumber) AS RecCnt
FROM tblEmployees AS Emp LEFT JOIN tblAttendence AS Att
ON Emp.EmployeeNumber=Att.EmployeeNumber
WHERE ([RptDur]=-14)
And (Emp.EmpStatusType="Active" And
Emp.PayType="per Hour"
And(Att.DateWeekStarting Between Nz([Enter Start Date],DateAdd("ww",[RptDur],Date()))
And Dateadd("ww",(([RptDur]*-1)-1),Nz([Enter Start Date],DateAdd("ww",[RptDur],Date()))))
Of course it does go on but I think that this should give you an idea of where I am trying to eventually go. Thanks the the response.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.