Count if with two scenarios

daytonshuman

New Member
Joined
Feb 23, 2007
Messages
6
I need to count rows that meet two criteria. Column B should equal "32456", and Column C should equal "FULLS". Both need to be met in order for it to count. Can someone help me with this. Thanks.
 

Excel Facts

Format cells as date
Select range and press Ctrl+Shift+3 to format cells as date. (Shift 3 is the # sign which sort of looks like a small calendar).
Welcome to the board...

Sumproduct is good for this..

=SUMPRODUCT(--(B1:B100=32456),--(C1:C100="FULLS"))

You may or may not need to add quotes around the 32456, depends if your data in column B is numbers, or "numbers stored as text"

Note, ranges cannot be entire column refs like B:B, must use row #s.
Unless in xl2007 or higher, and even then it's not recommended.
 
Upvote 0
If you do happen to have Excel 2007+ then the COUNTIFS function is a more efficient way

=COUNTIFS(B1:B100,32456,C1:C100,"FULLS")
 
Upvote 0

Forum statistics

Threads
1,211,685
Messages
6,103,291
Members
447,853
Latest member
olddutch7

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top