Sumif query

CVN55

New Member
Joined
Jun 14, 2017
Messages
29
Hi - what is wrong with this formula? I have used it successfully with sumproduct?
=SUMIF(H8:H106,--($B$8:$B$106="CARU")--($D$8:$D$106="Medical"))
Trying to add a column which contains the words CARU in one column and Medical in another...

Thank you,
Catherine
 

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.
you would need to use sumifs as you are looking for multiple conditions, as well as the syntax for sumif/sumifs is much different than sumproduct...

=SUMIFS(H8:H106,$B$8:$B$106,"CARU",$D$8:$D$106,"Medical")
 
Upvote 0
Your SUMIF formula is structured completely wrong. It looks like your wrote a SUMPRODUCT formula, and just swapped out the SUMPRODUCT for SUMIF.
SUMIF also only allows one conditions. SUMIFS allows more than one.
See: https://exceljet.net/excel-functions/excel-sumifs-function

So your formula should either be:
=SUMPRODUCT(H8:H106,--($B$8:$B$106="CARU")--($D$8:$D$106="Medical"))

or
=SUMIFS(H8:H106,B8:B106,"CARU",D8:D106,"Medical")
 
Last edited:
Upvote 0
Catherine

how about

=SUMIFS(H8:H106,$B$8:$B$106,"CARU",$D$8:$D$106,"Medical")

hope that works!


Ed
 
Upvote 0

Forum statistics

Threads
1,223,227
Messages
6,170,848
Members
452,361
Latest member
d3ad3y3

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