how to summarize total number of appearance in a column?

A

Alberta H K

Can you tell me how to summarize total number of appearance in a column?
For example, I have a column with three names appear at different rows
another column with value to the names:

John 45
Mary 15
John 33
Rick 10
Rick 11
Mary 31
Mary 22
John 0

How can I summarize: Number of times John appears (3 times),
and the total number in John's row (45+33+0=78).

Thank you.
 
P

Peo Sjoblom

=COUNTIF(A1:A10,"John")

=SUMIF(A1:A10,"John",B1:B10)

if you replace "John" with a cell like C1 you can use


=COUNTIF(A1:A10,C1)


=SUMIF(A1:A10,C1,B1:B10)


and just put the criteria in C1


--


Regards,


Peo Sjoblom
 
A

Alberta H K

Thank you Peo.

Can you give me an example of criteria in C1 should be?
Should C1 be a number?

Thank you. Alberta
 

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