SUMIFS question

Burrgogi

Active Member
Joined
Nov 3, 2005
Messages
495
Office Version
  1. 2010
Platform
  1. Windows
I have a very simple question regarding the SUMIFS function. I've created a spreadsheet containing all of my store purchases at a local store. Examples of categories are groceries and apparel. I want to sum up all the grocery purchases in June, July, August etc...

Here is my worksheet.


In an empty cell, I've entered the following formula but it's not working.
=SUMIFS(K18:K128,G18:G128,"Groc",B18:B128,"Jun")

My guess is that the "Jun" is not a valid criteria but i don't know how to fix that because purchase dates vary.
 
Last edited:

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
Thanks Aladin, but it doesn't work. Excel tells me there's an error. It does not specify what the error is, but it seems that it does not like
the "1Jun" part of the formula.
 
Upvote 0
Thanks Aladin, but it doesn't work. Excel tells me there's an error. It does not specify what the error is, but it seems that it does not like
the "1Jun" part of the formula.

=SUMIFS(K18:K128,G18:G128,"Groc",B18:B128,">="&"1Jun",B18:B128,"<="&EOMONTH("1Jun",0))

Actually, assuming that we have 2018 dates in B18:B128, we can have in B2 a criterion date like 2018-06-01,
in C2 a value like Groc, and in D2 invoke:

=SUMIFS(K18:K128,G18:G128,C2,B18:B128,">="&B2,B18:B128,"<="&EOMONTH(B2,0))
 
Upvote 0
=SUMIFS(K18:K128,G18:G128,"Groc",B18:B128,">="&"1Jun",B18:B128,"<="&EOMONTH("1Jun",0))

Actually, assuming that we have 2018 dates in B18:B128, we can have in B2 a criterion date like 2018-06-01,
in C2 a value like Groc, and in D2 invoke:

=SUMIFS(K18:K128,G18:G128,C2,B18:B128,">="&B2,B18:B128,"<="&EOMONTH(B2,0))

I meant to reply sooner and thank you for this. It was a very busy weekend for me. I had no idea there was a end of month function. Even if I did, I would not have been so expert at coming up with the correct formula. Thank you Aladin!

Edit: by the way, what exactly is the difference between the 2 formulas? I don't quite understand it.
 
Last edited:
Upvote 0
I meant to reply sooner and thank you for this. It was a very busy weekend for me. I had no idea there was a end of month function. Even if I did, I would not have been so expert at coming up with the correct formula. Thank you Aladin!

You are welcome.

Edit: by the way, what exactly is the difference between the 2 formulas? I don't quite understand it.

The second is copiable in principle: You can have a different set of criteria in B3 and in C3 and copy down the formula to D3...

=SUMIFS($K$18:$K$128,$G$18:$G$128,C2,$B$18:$B$128,">="&B2,$B$18:$B$128,"<="&EOMONTH(B2,0))
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

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