SumProduct: Find value at intersection

gheyman

Well-known Member
Joined
Nov 14, 2005
Messages
2,347
Office Version
  1. 365
Platform
  1. Windows
I have Peoples Names down A starting in Row 2 down to 10 and Product ID in Row 1 starting in B thru H. My Values are in B2:H10

SumProduct((Indirect("SHeet1!$A$2:$A$10")=A1)*(Indirect("SHeet1!$B$1:$H$1")=B1)*(Indirect("SHeet1!$B$2:$H$10"))

Gives me an error

What am I doing wrong?

Thanks
 

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
An Index with two Match formula gets me what I need in this instance.

But here is the formula I have in another workbook where I used the Sumproduct. This formula works

=SUMPRODUCT((INDIRECT("Cost_Data!$A$4:$A$1000")=$C$3)*(INDIRECT("Cost_Data!$D$4:$D$1000")=$D6)*(INDIRECT("Cost_Data!$I$3:$O$3")=I$4)*INDIRECT("Cost_Data!$I$4:$O$1000"))
OK, I am not quite sure I understand how that is working (especially without access to see what that data all looks like). I am guessing that you probably had someone write that for you? If so, that person might be your best bet in adapting the code to work for you.

I am still not quite clear on what this output you want looks like, whether you are wanting to return a single value, a subset of data, etc.
Without having a full understanding of exactly what you are after, I don't think there is much more I can offer.
If you can post images of example data and what your expected results should look like, that would go a long way.
 
Upvote 0
@ gheyman:

The formula from Post # 1 is missing a closing bracket -- otherwise it works OK.

What I don't understand is why you need the INDIRECTs.

Will the following work for you?

=SUMPRODUCT((Sheet1!$A$2:$A$10=A1)*(Sheet1!$B$1:$H$1=B1),Sheet1!$B$2:$H$10)
 
Upvote 0

Forum statistics

Threads
1,223,911
Messages
6,175,326
Members
452,635
Latest member
laura12345

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