Ask Your Question
0

Sum up based on date in the same row

asked 2017-08-28 13:00:20 +0200

rrlucca gravatar image

Hi there,

I'd like to sum up a column if and only if other column say so. I thought it could be done with SUMIF. My problem is that I have a sheet with dates on column A and values on column B and I am trying to do weekday report of progress...

My first try was something like this: "=SUMIF(B1:B100,WEEKDAY(A1)=3)". It is obivious wrong because it sums up all elements or it does nothing. I'd like when I try to sum up B2 I test B1 and not A1. Sum up B3, test A3 and so on.

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2017-08-28 13:35:50 +0200

JohnSUN gravatar image

updated 2017-08-28 15:28:18 +0200

What about =SUMPRODUCT(B1:B100;WEEKDAY(A1:A100;2)<6)? This formula must calculate the sum of the values for all working days.

If you need data for each day of the week, then use ...WEEKDAY(A1:A100;2)=1 for Monday, ...=2 for Tuesday, etc.

edit flag offensive delete link more

Comments

Thanks. Worked fine.

rrlucca gravatar imagerrlucca ( 2017-08-28 16:41:36 +0200 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2017-08-28 13:00:20 +0200

Seen: 151 times

Last updated: Aug 28 '17