Formula for calculationg hours worked per day

M

Msobral

I'm creating a log for our employees to enter worked hours. The log has a
client column, a weekday drop daown list, a date column, an employee name
drop down list, a task description column, and an Hrs. column ( to enter
amount of hours worked on that specific task).
I have a Weekly Total section and what I would like to add is a section that
adds the amout of hours worked by weekday ( 8 hrs. on monday, 7 hrs. on
tuesday and so on ).
I don't know what formula to use. Could you please help? I'm really stuck!!!
 
M

Msobral

That is helpful for a regular office employee. This are techs, so they split
their time between customers. The entries look pretty much like this:

Cutomer Day Date Task Hours
Smith Tuesday 07/03/07 Work on VOIP 2.5
Johnson Thursday 07/05/07 PC Setup 4.0
Weekly Total 6.5
Now I want to have the following:

Hrs Worked per Day
Sat Sun Mon Tue Wed Thu Fri
0 0 0 2.5 0 4.0 0

Any ideas on what to use?
 
S

S.Y.M. Wong-A-Ton

You can use the sum() function over the "Hours" field with a filter on the
value of the "Day" field to calculate the total for each day field in your
totals section. The formula could look something like:

sum(../my:group1/my:group2/my:Hours[../my:Day = "Monday"])

to calculate the total hours over all rows that have "Monday" selected. You
can use rules for this; no need to write code. The only disadvantage is that
if you remove a row in your repeating table, the recalculation will not take
place. You will have to use a button to perform the recalculation.

If you need more instructions on how to get this done, let me know; I'll
walk you through it.
 
M

Msobral

Thank you SO much! It actuallly worked great!

S.Y.M. Wong-A-Ton said:
You can use the sum() function over the "Hours" field with a filter on the
value of the "Day" field to calculate the total for each day field in your
totals section. The formula could look something like:

sum(../my:group1/my:group2/my:Hours[../my:Day = "Monday"])

to calculate the total hours over all rows that have "Monday" selected. You
can use rules for this; no need to write code. The only disadvantage is that
if you remove a row in your repeating table, the recalculation will not take
place. You will have to use a button to perform the recalculation.

If you need more instructions on how to get this done, let me know; I'll
walk you through it.
---
S.Y.M. Wong-A-Ton


Msobral said:
That is helpful for a regular office employee. This are techs, so they split
their time between customers. The entries look pretty much like this:

Cutomer Day Date Task Hours
Smith Tuesday 07/03/07 Work on VOIP 2.5
Johnson Thursday 07/05/07 PC Setup 4.0
Weekly Total 6.5
Now I want to have the following:

Hrs Worked per Day
Sat Sun Mon Tue Wed Thu Fri
0 0 0 2.5 0 4.0 0

Any ideas on what to use?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top