Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hi,
New to Power BI and DAX so please bear with me - For context and to simplify, I have a selection of products of which, we apply a performance 'score' to the material they are made from.
I have been tasked to create a report that when a particular product is selected, it's material perfomance 'score' is compared to the other products in the list.
To clarify using the example below:
Using a visual like a bar chart it would be great to see the variance of the other products material performance to the product selected. So if 'Product 1' was selected the variances would be as follows:
If I selected 'Product 2' the variances would change accordingly.
This would be so powerful for some reporting I am doing for a number of reasons but no matter what I try I cannot seem to get this to work. I have managed to create a 'hack' version where I have created a SELECTVALUE measure and then subtracted the particular perfomance score from this, which looks a little like this:
Solved! Go to Solution.
Hi , @SESLewis
According to your description, you want to "Comparison to Selection Query".
Now, i have found no way to update the measures' name according to the filter selection.
Here are the steps you can refer to :
(1)This is my test data:
(2)We need to click "New Table" to create a calculated table as a slicer and we do not need to create any relationship between two tables:
Table 2 = VALUES('Table'[Product])
(3)I create a measre to test :
Var to Product = var _select = MAX('Table 2'[Product])
var _t =FILTER( ADDCOLUMNS( ALLSELECTED('Table'[Product]) , "value" , [Material Performance Measure]) , [Product] = _select)
return
[Material Performance Measure]-SUMX(_t ,[value])
Then we can put the fields we need on the visual adn we can meet your need:
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Is there any way to do something like this, but with a KPI? Where [Material Performance Measure] is the callout value, and [Var to Product] is the target?
Many thanks Aniya! This has helped me alot and I have managed to apply this to what I have been working on. I hope this helps others where comparisons are needed without date ranges.
Regards
Hi , @SESLewis
According to your description, you want to "Comparison to Selection Query".
Now, i have found no way to update the measures' name according to the filter selection.
Here are the steps you can refer to :
(1)This is my test data:
(2)We need to click "New Table" to create a calculated table as a slicer and we do not need to create any relationship between two tables:
Table 2 = VALUES('Table'[Product])
(3)I create a measre to test :
Var to Product = var _select = MAX('Table 2'[Product])
var _t =FILTER( ADDCOLUMNS( ALLSELECTED('Table'[Product]) , "value" , [Material Performance Measure]) , [Product] = _select)
return
[Material Performance Measure]-SUMX(_t ,[value])
Then we can put the fields we need on the visual adn we can meet your need:
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly