Sumproduct and Sumifs

chaboyski

Board Regular
Joined
Aug 18, 2020
Messages
57
Office Version
  1. 2016
Platform
  1. Windows
Hi Guys,

would this 2 be possible to be combined?

heres a scenario:

1667512400996.png


this is the simplest formula. but the problem is, i needed to use Sumifs to capture selected datas only.

i Tried this:

1667512556921.png


SUMIFS(Dump!D:D,Dump!B:B,Summary!$A$1,Dump!C:C,Summary!E26) would be what should be like the Column C in the first image
SUMIFS(Dump!G:G,Dump!B:B,Summary!$A$1,Dump!C:C,Summary!E26) would be what should be like the Column B in the first image

would it be possible?

Thank you in Advance!
 

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney
You can add criteria to SUMPRODUCT using arrays, for example --(B:B=$A$1)

Either use a realistic number of rows, or dynamic arrays with this. Full columns will be slow to calculate.

You can then do SUMPRODUCT/SUMIFS for the final result.

I'll try and do a full formula later if you get stuck, posting from phone at the moment and they're not easy to write on here.
 
Upvote 0
thank you! I can send you my sample file but i dont know how to attach it here. - maybe instead of selecting the whole column i can just select some - the downside might be the data would be more than the selected sell.

the below image would show you where the sumifs is getting the data. sumifs was added since i needed to get only data for my company and the extracted raw include everyone.

1667553637462.png
 
Upvote 0
maybe instead of selecting the whole column i can just select some - the downside might be the data would be more than the selected sell.
If you know that there would never be more than 2000 rows then you could use that as a the range size. It doesn't have to be exact. Even 100k rows is better than the entire column.

=SUMPRODUCT(Dump!$G$9:$G$2000,Dump!$D$9:$D$2000,--(Dump!$B$9:$B$2000=Summary!$A$1),--(Dump!$C$9:$C$2000=Summary!E26))/SUMIFS(Dump!$G$9:$G$2000,Dump!$B$9:$B$2000,Summary!$A$1,Dump!$C$9:$C$2000,Summary!E26)

Do you know how to create named ranges? You can use them to find the last row containing data.

If you already know how then it will make things a lot easier as I will have much less to explain to you.
 
Upvote 0
Solution
i dont know how to create named ranges but it is all good. data most probably wont be eating more than 2k columns.

with the formula that you have given - just to confirm, you first got the datas from columns D and G and then used the -- to check the other conditions, right?


1667566019187.png
 
Upvote 0
That is correct, I used your sumifs formulas from post 1 and based the new formula on that
 
Upvote 0
yea and im really thankful! every formula fits. but when i try to run use it, it shows #value!. would there be other options?
 
Upvote 0
Do you have any #VALUE! errors in the columns of the Dump sheet that the formula refers to?

Looking at the formula and your screen capture in post 5, I can think of no other reason for that error to occur.
 
Upvote 0
YESSSSSS! thank you so much! its the freakin Time. appreciate the help.
 
Upvote 0

Forum statistics

Threads
1,214,907
Messages
6,122,181
Members
449,071
Latest member
cdnMech

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