Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi,
I'm looking to create a measure that sums up the total YTD "comparison" per supplier, material and category.
so far I got it to work on supplier level but from material level up results are off.
link to PBIX: https://we.tl/t-LzZmHP4ldl
expected results:
Hi @RK91 ,
You could create a measure by the following formula:
cumulative2 =
VAR _A =
CALCULATE ( [cumulative], 'Material'[Supplier] = " A" )
VAR _B =
CALCULATE ( [cumulative], 'Material'[Supplier] = " B" )
VAR _COUNT =
DISTINCTCOUNT ( 'Material'[Supplier] )
RETURN
IF (
_COUNT = 1
&& MAX ( [Supplier] ) = " A",
_A,
IF ( _COUNT = 1 && MAX ( [Supplier] ) = " B", _B, _A + _B )
)
The final output is shown below:
Best Regards,
Community Support Team_ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
hi @v-yalanwu-msft, thank you for reaching out. I thought I already replied but didn't - sorry.
Although it works on material level it doesn't give the expected result for the category. Also I have a lot more suppliers, materials and categories in my actual data and therfor I think it's not a sustainable solution in this case.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
113 | |
97 | |
79 | |
73 | |
56 |
User | Count |
---|---|
145 | |
105 | |
104 | |
90 | |
63 |