Sumproduct of Sumproduct / or / Sumproduct of Sumifs

yayo12

New Member
Joined
May 26, 2008
Messages
4
Hello guys,

I have been working on a file for quite sometime, and I finally hit the wall. I simply cannot find a workaround to the following question.

I have an original table that i was able to summarize using index(match) so now the new table looks something like this

[TABLE="width: 500"]
<tbody>[TR]
[TD]Product[/TD]
[TD]Prod Desc[/TD]
[TD]Channel[/TD]
[TD]Qty M01[/TD]
[TD]Qty M02[/TD]
[TD]Price M01[/TD]
[TD]Price M02[/TD]
[/TR]
[TR]
[TD]Ball[/TD]
[TD]
round[/TD]
[TD]store[/TD]
[TD]5[/TD]
[TD]8[/TD]
[TD]$10[/TD]
[TD]$20[/TD]
[/TR]
[TR]
[TD]Ball[/TD]
[TD]round[/TD]
[TD]online[/TD]
[TD]6[/TD]
[TD]8[/TD]
[TD]$15[/TD]
[TD]$30[/TD]
[/TR]
[TR]
[TD]Ball[/TD]
[TD]yellow[/TD]
[TD]store[/TD]
[TD]3[/TD]
[TD]6[/TD]
[TD]$5[/TD]
[TD]$15[/TD]
[/TR]
[TR]
[TD]Ball[/TD]
[TD]red[/TD]
[TD]online[/TD]
[TD]4[/TD]
[TD]8[/TD]
[TD]$2[/TD]
[TD]$20[/TD]
[/TR]
</tbody>[/TABLE]

Ok, so now that I have the table above, I now want to summarize even more by Product and Channel, hence, my new table looks like this:

[TABLE="width: 500"]
<tbody>[TR]
[TD]Product[/TD]
[TD]Channel[/TD]
[TD]Qty M01[/TD]
[TD]Qty M02[/TD]
[TD]Price M01[/TD]
[/TR]
[TR]
[TD]Ball[/TD]
[TD]store[/TD]
[TD]8[/TD]
[TD]14[/TD]
[TD]??[/TD]
[/TR]
[TR]
[TD]Ball[/TD]
[TD]Online[/TD]
[TD]10[/TD]
[TD]16[/TD]
[TD]??[/TD]
[/TR]
</tbody>[/TABLE]

I used sumproduct and sumifs(index(match) and both formulas worked great for the quantity on columns "Qty M01 and Qty M02" since this is a simple addition of units.

My issue is on the price, since I need a weighted average of price per units.
I have tried every single variation of nesting sumproducts or sumproduct(sumif) and they all show the same result. Both formulas are actually multiplying the result of qty * price
In the above example what I need the formula to do is what a usual sumproduct would do (5*$10)+(3*$5) = 65
Yet my result is (5+3)*($10+$5) = 120

What formula can I use?
Thank you so much
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"
Try:
Excel Workbook
ABCDEFG
1ProductProd DescChannelQty M01Qty M02Price M01Price M02
2Ballroundstore58$10$20
3Ballroundonline68$15$30
4Ballyellowstore36$5$15
5Ballredonline48$2$20
6
7ProductChannelQty M01Qty M02Price M01
8Ballstore81465
9BallOnline101698
Sheet
 
Upvote 0
Thank you so much
Worked perfectly. I sometimes forget that simplicity is key! :)
I was trying something utterly complicated.
 
Upvote 0

Forum statistics

Threads
1,224,812
Messages
6,181,102
Members
453,021
Latest member
Justyna P

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