Quarterly Overtime Hours

  • Thread starter Thread starter Rudy
  • Start date Start date
R

Rudy

I have several queries to keep track of hours and
overtime hours. However, I'd like a query that general
overtime hours by the quarter. So that at the end of a
quarter I can track this value. I've been using the IIf
function to try. This is what I've tried.

OTHours: IIf([Sum Of Hours Worked]>'q yyyy',[Sum Of Hours
Worked]-'q yyyy',0)

Can you suggest an alternative that works
 
You should be able to do this with a Totals Query.

SELECT Format([WorkDate],"q yyyy") AS TheQtr, Sum(HoursWorked) AS
SumOfHoursWorked
FROM YourTable
GROUP BY Format([WorkDate],"q yyyy");
 
Back
Top