Sum with some criteria

freddocp

New Member
Joined
Sep 28, 2024
Messages
6
Office Version
  1. 365
Platform
  1. Windows
Please, I am having some challenges with a sum with a few criteria, please view the sample attached.

1- I need to sum up the same Part Numbers (column A) I made an example with Descr 2 and Descr 15.

2- Just sum up the different lots (Column B) the lot that has some repeated should not be included in the sum.

3- Status (column C) only consider the terms with ?Demand? in the sum.

In column E: the values I need as a result. For the examples Descr 2 and Descr 15

Note: Remember that you'll need to fill in the whole spreadsheet afterward.

Sum with a few criteria - Rev.0.xlsx
G
12
Sheet1


Thank you in advance.
tela 2024-09-28 135916.png
 
I see. Hopefully you could go with something like this (please adjust ranges):

Excel Formula:
=LET(
a,HSTACK($C$2:$C$5,$F$2:$F$5,$N$2:$N$5,$U$2:$U$5),
f,UNIQUE(FILTER(a,($F$2:$F$5=F2)*($N$2:$N$5="On hand"))),
IF(N2="Supply",0,SUM(CHOOSECOLS(f,4))))
Thank you very much! :)
 
Upvote 0

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
Thank you very much! :)
The marked solution has been changed accordingly. In your future questions, please mark the post as the solution that actually answered your question, instead of your feedback message as it will help future readers. No further action is required for this thread.

BTW, when using XL2BB you need to first select the range on your worksheet that you want to show before clicking 'Mini Sheet'. In your earlier posts it looks like you just have had a blank cell selected when you clicked the Mini Sheet button
 
Upvote 0

Forum statistics

Threads
1,222,626
Messages
6,167,157
Members
452,099
Latest member
Auroraaa

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