Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreGet certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now
Hello,
I'm struggling with the sum of quantities per partnumber. Our machines have framenumbers and those machines are build with parts. I would like to sum the parts in an overview.
This is the data:
Framenumber | PartNumber | Quantity |
01504M | 112455 | 2 |
01504M | 238574 | 22 |
01504M | 598749 | 5 |
01504M | 254875 | 4 |
01504M | 254152 | 11 |
01504M | 658745 | 23 |
01504M | 158965 | 1 |
01504M | 128544 | 45 |
01504M | 123659 | 7 |
01504M | 128588 | 9 |
01504M | 124588 | 2 |
01605D | 112455 | 2 |
01605D | 238574 | 22 |
01605D | 598749 | 5 |
01605D | 254875 | 4 |
01605D | 254152 | 11 |
01605D | 658745 | 23 |
01605D | 158965 | 1 |
01605D | 128544 | 45 |
01605D | 123659 | 7 |
01605D | 128588 | 9 |
01605D | 124588 | 2 |
07822E | 112455 | 2 |
07822E | 238574 | 22 |
07822E | 598749 | 5 |
07822E | 254875 | 4 |
07822E | 254152 | 11 |
07822E | 658745 | 23 |
07822E | 158965 | 1 |
07822E | 128544 | 45 |
07822E | 123659 | 7 |
07822E | 128588 | 9 |
07822E | 124588 | 2 |
And the result should look like this:
PartNumber | Quantity |
112455 | 6 |
238574 | 66 |
598749 | 15 |
254875 | 12 |
254152 | 33 |
658745 | 69 |
158965 | 3 |
128544 | 135 |
123659 | 21 |
128588 | 27 |
124588 | 6 |
112455 | 6 |
238574 | 66 |
598749 | 15 |
254875 | 12 |
254152 | 33 |
658745 | 69 |
158965 | 3 |
128544 | 135 |
123659 | 21 |
128588 | 27 |
124588 | 6 |
I tried this but it seems that the total QTY is summed and multiplied by three:
Solved! Go to Solution.
oh okay @WLFRD , then try this:-
Column =
CALCULATE (
SUM ( 'ProductionPartAll'[Quantity] ),
FILTER (
'ProductionPartAll',
'ProductionPartAll'[PartNumber] = EARLIER ( 'ProductionPartAll'[PartNumber] )
)
)
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
Hi @WLFRD ,
You can directly drag your partnumber and Quantity column then mark Quantity column summerization as Sum.
Thanks,
Samarth
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
Thanks! But I would like to have a calculated column. I need this total column for another calculation.
oh okay @WLFRD , then try this:-
Column =
CALCULATE (
SUM ( 'ProductionPartAll'[Quantity] ),
FILTER (
'ProductionPartAll',
'ProductionPartAll'[PartNumber] = EARLIER ( 'ProductionPartAll'[PartNumber] )
)
)
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
Is it possible to make the calculation dynamic? I mean, based on how we filter the data, it has to calculate the sum per PartNumber.
what result are you getting? can you share?
I get this result from your measure
Proud to be a Super User!
Is it possible to make the calculation dynamic? I mean, based on how we filter the data, it has to calculate the sum per PartNumber.
This is my result in Power BI:
PartNumber | Total_QTY_Per_PartNumber |
128544 | 405 |
658745 | 207 |
238574 | 198 |
254152 | 99 |
128588 | 81 |
123659 | 63 |
598749 | 45 |
254875 | 36 |
112455 | 18 |
124588 | 18 |
158965 | 9 |
Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
User | Count |
---|---|
94 | |
86 | |
82 | |
70 | |
49 |
User | Count |
---|---|
143 | |
122 | |
109 | |
60 | |
55 |