Count alternative to SUMPRODUCT?

bsnapool

Active Member
Joined
Jul 10, 2006
Messages
452
Is there a count alternative to sum product?

I have data in column D > if this = "M" and column R = "Sic" then i would like to count how many "M" there are in column D.

Any ideas>?

Thanks in advance..

Andrew
 

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"
Not sure why you want an "alternative to sum product"... why not use =SUMPRODUCT(--(D1:D100="M"),--(R1:R100="Sic")) to get the count?
 
Upvote 0
Try...

=SUMPRODUCT(--(D2:D100="M"),--(R2:R100="Sic"))

Hope this helps!
 
Upvote 0
Not sure why you'd want an alternative but:

=SUM(IF(D1:D100="M",IF(R1:R100="Sic",1)))

which needs to be confirmed with Ctrl+Shift+Enter

Richard
 
Upvote 0
Thanks for all your responses...

Was under the impression that SUMPRODUCT, would sum only numbers... Friday, need to go home!!

Thanks
 
Upvote 0
SUMPRODUCT does only work with numbers, that is why the use of --, it is coercing the TRUE/FALSE values to 1 and 0 respectively.
 
Upvote 0

Forum statistics

Threads
1,215,034
Messages
6,122,782
Members
449,095
Latest member
m_smith_solihull

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