sum grouping

K

KLock

If I have the following entries
Reason Time
Reason1 50
Reason3 45
Reason3 40
Reason2 35
Reason1 65

What function will give me the output?
Reason total time
Reason1 115
Reason2 35
Reason3 80

A pivot table would not work for me as I am trying to sum tables from
different tabs. Thank you for any help.
 
A

Alan

With the data in A1:5 and B1:5

=SUMPRODUCT(--($A$1:$A$5=A1),--($B$1:$B$5))

Drag it down to the end of the data list,
Regards,
Alan.
 
K

klock

Alan,

I was thinking along the lines of sumproduct. Just to better understand
what does the "--" do?
 
J

John

Hi KLock
You could also use this : =SUMIF(A2:A6,"=Reason1",B2:B6) adjust range to your
needs.
HTH
John
 
J

John

Hi KLock
The -- is called a Double Unary, it changes trues and falses
to 1's and 0's. Logic expression to numeric expression.
HTH
John
 

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