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 All,
I have calculated the Gross Margin % using Price and Cost value by Item vise.
Every Item having the Upper bound and lower bound, to calculate the Margin violation, as below
My Issue is: I need to count the Items, which Margin% is out of lower and upper bound i.e,
count items only if Gross Margin % > UpperBound and Gross Margin% < Lower Bound
ignore if the lower and upper bound is blank
Any help there? I'm was searching through community posts but nothing worked for me
Thanks,
Solved! Go to Solution.
Try this:
Measure =
SUMX(
SUMMARIZE(
ItemTable ,
ItemTable[ItemNumber] ,
"Value" , IF( OR([Gross Margin %] < ItemTable[Lower Bound] , [Gross Margin %] > ItemTable[Upper Bound]) , 1 , 0 )
) , [Value]
)
/ J
Try this:
Measure =
SUMX(
SUMMARIZE(
ItemTable ,
ItemTable[ItemNumber] ,
"Value" , IF( OR([Gross Margin %] < ItemTable[Lower Bound] , [Gross Margin %] > ItemTable[Upper Bound]) , 1 , 0 )
) , [Value]
)
/ J
@Anonymous , you can have two what if parameter Lower and upper
and create a measure like
measure 1 = countx(filter(summarize(table, table[Itemnumber], "_1", [Gross Margin %]), [_1] >=selectedvalue(Lower[Lower]) && [_1] <=selectedvalue(upper[upper])),[Itemnumber])
or static value
Measure 2 = countx(filter(summarize(table, table[Itemnumber], "_1", [Gross Margin %]), [_1] >=.1 && [_1] <=.2),[Itemnumber])
what-if
https://docs.microsoft.com/en-us/power-bi/desktop-what-if
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 |
---|---|
104 | |
95 | |
80 | |
67 | |
62 |
User | Count |
---|---|
146 | |
110 | |
107 | |
86 | |
63 |