ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Mutliple Sumproduct criteria (https://www.excelbanter.com/excel-worksheet-functions/237859-mutliple-sumproduct-criteria.html)

PJFry

Mutliple Sumproduct criteria
 
I have three columns, Vendor, Price and Quantity on a data tab. On a summary
tab I have all of my vendors. How can I do a sumproduct (price and quantity)
by vendor on my summary tab?

I have been sorting my data by vendor and manually selecting the sumproduct
range, but as we add vendors, this will be come unmanageable.

Thanks!

--
Regards,

PJ
Please rate this post using the vote buttons if it was helpful.


smartin

Mutliple Sumproduct criteria
 
PJFry wrote:
I have three columns, Vendor, Price and Quantity on a data tab. On a summary
tab I have all of my vendors. How can I do a sumproduct (price and quantity)
by vendor on my summary tab?

I have been sorting my data by vendor and manually selecting the sumproduct
range, but as we add vendors, this will be come unmanageable.

Thanks!


No need to sort. Try something like this on your Summary worksheet @ B2,
where the vendor ID is in A2, and fill down:

=SUMPRODUCT((Data!$A$2:$A$11=Summary!$A2)*(Data!$B $2:$B$11)*(Data!$C$2:$C$11))

Alternative syntax:

=SUMPRODUCT(--(Data!$A$2:$A$11=Summary!$A2),(Data!$B$2:$B$11),(D ata!$C$2:$C$11))


All times are GMT +1. The time now is 05:39 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com