How to get Countif to work this out?
Nel ,
Wind54Surfer ha scritto:
Hi all,
I have as an example:
Columns
A B
apples----------------------2
oranges--------------------3
apples----------------------4
apples----------------------5
oranges--------------------3
How can I get the totals: apples=11 and oranges=6 using Countif
Any help is greatly appreciated,
Emilio
Hi Emilio,
instead you should use the SUMIF function, so if yur table is A2:B5, to have
the sum of apples you can use the formula:
=SUMIF(A2:A5;"apples";B2:B5)
or, better, if you use a cell to fix the criteria, for example C2, the
formula will be:
=SUMIF(A2:A5;C2;B2:B5)
in this way if you write in C2 apples, the formula will return 11, if you
write oranges you will have 6.
--
(I'm not sure of names of menus, options and commands, because
translating from the Italian version of Excel...)
Hope I helped you.
Thanks in advance for your feedback.
Ciao
Franz Verga from Italy
|