Skip to main content
cancel
Showing results for
Search instead for
Did you mean:

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Helper III

## Return Specific Value from Measure

Hi All,

I have a running total percentage messure [Pareto] based on an inventory table

I want to return the largest value from the [Inventory Value] messure from the ItemID > 0.50 for messure [Pareto]

Example:

 BranchID ItemID Inventory Value PI Pareto Inventory Rank1 DB01 500083704 6361.2 0.391 1 DB01 500056144 5000 0.699 2 DB01 500078377 4883.904 1 3

Th expected output would be 5000, the [Inventory Value] that is largest and over 0.50 [Pareto]

[Inventory Sample]

 BranchID ItemID LotNumber Quantity MAC Total MAC AT01 500051583 P8Z0B 29 4 = Quantity x MAC AT01 500051583 P8Z0B 7138 4 AT01 500051586 8CHHB 7200 6 AT01 500051586 BX4FB 5 6 AT01 500051586 B1DFB 2300 6 AT01 500051586 026FB 258 6 CL01 500051580 K9PHB 100 1 CL01 500051580 K9PHB 200 1 CL20 500051588 YL2FB 350 8

``````Pareto =
var InventoryValue = [Inventory Value]
var ALLIV = CALCULATE([Inventory Value], ALLSELECTED(Inventory) )

return
DIVIDE(
SUMX(
FILTER(
SUMMARIZE(ALLSELECTED(Inventory), Inventory[ItemID],
"Dollars", [Inventory Value]),
[Dollars] >= InventoryValue ),
[Dollars]),
ALLIV)``````

``````Inventory Value =
SUM(Inventory[Total MAC])``````

2 REPLIES 2
Community Support

What is the relationship between your example and [Inventory Sample]? The two tables seem to be different.

If I understand correctly, you want to create a measure named 'Pareto'. How do you get the percentage of your Pareto measure? Is Inventory Value divided by the sum of all Inventory Values?

Best Regards,

Stephen Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Super User

Please correct me if I wrongly understand your point.

In order to find higher than 50% Pareto && highest quantity ->

Please check the below picture if it is what you needed.

Outcome =
VAR newtable =
FILTER (
SUMMARIZE (
ALLSELECTED ( Inventory ),
Inventory[ItemID],
Inventory[Quantity],
"@pareto", [Pareto]
),
[@pareto] >= 0.5
)
RETURN
MAXX ( newtable, Inventory[Quantity] )

Did I answer your question? Mark my post as a solution!

Appreciate your Kudos!!

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.

Click here and Go to My LinkedIn Page

## Helpful resources

Announcements

#### Power BI Monthly Update - July 2024

Check out the July 2024 Power BI update to learn about new features.

#### Fabric Community Update - July 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors