Count fuction

H

Helen

Hi,

I am trying to find a formula that will be best for the below situation i am
having.


Lets say I have a data as below, I want to know how I can find the count of
B for Q1B01. All the blanks I can't delet, so basically my table is set up as
below.
A B
Q1B01 H10F001
Q1B01 H10F002
Q1B01
Q1B01 H10F003
Q1B01 H10F004
Q1B01
Q1B01 H10F005
Q1B01
Q1B01 H10F006
Q1B01
Q1B02 0905036
Q1B02 0905037
Q1B03 P005750
Q1B03 P005751
Q1B03 P005752
Q1B04 0906278
Q1B04 0906279
Q1B04 0906280
Q1B04 0906281
Q1B05 H10F007
Q1B05 H10F008
Q1B05 H10F009
Q1B05 H10F010
Q1B05 H10F011
Q1B05 H10F012
Q1B05 H10F013
Q1B05 H10F014
Q1B05 H10F015
Q1B05
Q1B05 H10F016
Q1B05
Q1B05 H10F017
Q1B05 H10F018
 
J

Jacob Skaria

Hi Helen

You can use COUNTIF(). With Q1B01 in C1; try formula in D1 as show below;



Col A Col B Col C Col D
Q1B01 H10F001 Q1B01 =COUNTIF(A:A,C1)
Q1B01 H10F002 Q1B02 =COUNTIF(A:A,C2)
Q1B01
Q1B01 H10F003
Q1B01 H10F004
Q1B01
Q1B01 H10F005
Q1B01
Q1B01 H10F006
Q1B01
Q1B02 905036

If this post helps click Yes
 
P

Pete_UK

Try this:

=SUMPRODUCT((A1:A100="Q1B01")*(B1:B100<>""))

Adjust the ranges to suit your data.

Hope this helps.

Pete
 
J

Jacob Skaria

To avoid blank entries try the below...in D1

Col C Col D
Q1B01 =SUMPRODUCT(--($A$1:$A$100=C2),--($B$1:$B$100<>""))
Q1B02 =SUMPRODUCT(--($A$1:$A$100=C3),--($B$1:$B$100<>""))



If this post helps click Yes
 

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