SUMIFS Formula

mj_1986

New Member
Joined
Jun 10, 2015
Messages
6
Hi,
I am trying to SUMIFS based on 2 criteria - number and a description but the sumif wont differentiate between the 8502 and the 850200 codes and is therefore suming both rather than just the one that i want.

I am using this formula but something is missing. How do i fix this so the get 600 for 1111.8502 & 600 for 1111.850200

Thank you!

1704334471097.png
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
Use the following, but you will have to limit the range

varios 03ene2024.xlsm
ABCDEFG
1
21111.8502APPLES6001111.8502APPLES100
31111.850200APPLES8001111.8502APPLES200
41111.8502APPLES300
51111.85020ORANGES400
61111.85020BANANAS500
71111.850200APPLES800
Hoja2
Cell Formulas
RangeFormula
C2:C3C2=SUMPRODUCT(($E$2:$E$100=A2)*($F$2:$F$100=B2)*($G$2:$G$100))
 
Upvote 0
Please edit your profile to show the version of Excel that you use.
I included a formula that requires a fairly recent version of Excel.
I assumed columns A and E are text

Sumifs.xlsm
ABCDEFGHI
1TextText
21111.8502APPLES6001111.8502APPLES100600
31111.850200APPLES8001111.8502APPLES200800
41111.8502APPLES300
51111.8502ORANGES400
61111.8502BANANAS500
71111.850200APPLES800
8
4f
Cell Formulas
RangeFormula
C2:C3C2=SUMPRODUCT(--($E$2:$E$20=A2),--($F$2:$F$20=B2),($G$2:$G$20))
I2:I3I2=SUM(($E$2:$E$20=A2)*($F$2:$F$20=B2)*($G$2:$G$20))
 
Upvote 0
Solution
Hi Dante, thanks for this! How have you formatted the data because I am still getting the same result as before where as you as have the correct result.

Or is this something to do with 'limiting the range'? How do I do this?
 
Upvote 0
Please edit your profile to show the version of Excel that you use.
I included a formula that requires a fairly recent version of Excel.
I assumed columns A and E are text

Sumifs.xlsm
ABCDEFGHI
1TextText
21111.8502APPLES6001111.8502APPLES100600
31111.850200APPLES8001111.8502APPLES200800
41111.8502APPLES300
51111.8502ORANGES400
61111.8502BANANAS500
71111.850200APPLES800
8
4f
Cell Formulas
RangeFormula
C2:C3C2=SUMPRODUCT(--($E$2:$E$20=A2),--($F$2:$F$20=B2),($G$2:$G$20))
I2:I3I2=SUM(($E$2:$E$20=A2)*($F$2:$F$20=B2)*($G$2:$G$20))
Is there a way to Further distinguish between APPLES and Apples? Ie. tacking into account whether its upper case or lower case?
 
Upvote 0
What version of Excel are you using?
" Is there a way to Further distinguish between APPLES and Apples? Ie. tacking into account whether its upper case or lower case?
The formula may not be very efficient.


Revise to your requirements

Sumifs.xlsm
ABCDEFGHI
1TextText
21111.8502APPLES6001111.8502APPLES100100
31111.850200APPLES8001111.8502APPLES200200
41111.8502apples3000
51111.8502ORANGES4000
61111.8502BANANAS5000
71111.850200APPLES8000
8
4f
Cell Formulas
RangeFormula
C2:C3C2=SUMPRODUCT(--($E$2:$E$20=A2),--($F$2:$F$20=B2),($G$2:$G$20))
I2:I7I2=AND(EXACT(F2,B$2),E2=A$2)*G2
 
Upvote 0

Forum statistics

Threads
1,215,135
Messages
6,123,238
Members
449,093
Latest member
Vincent Khandagale

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