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

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.

Reply
Thraciel
New Member

Multiply filtered values by different factors from a parameter

Hi guys,

 

I am just getting started with PowerBI and ran into some trouble when doing some DAX calculations.

 

I have a table with different (but not distinct) identification numbers. I created a measure to calculate something from the different Columns row by row.

 

Due to some filters in the report, I can get 1 or 2 lines in the table. Now I want to have a parameter slicer to adjust a percentage value (Value from the slicer and 1-value from the slicer)

 

Now I have to multiply the resulting rows (if more than 1) one time with the slicer value and one time with the 1-slicer value

How can I achieve that?

 

To make it more clear some example:

ID No.Product IDCapacity Value for one product only(SUMX or Calculated Column)
1026591130514101.000.000
102659113051412500.000

(The combination of ID No. and Product ID is unique)

 

Slicer Value set to 0.2

 

So the expected result would be:

ID No.Product IDResult
1026591130514101.000.000*0,2 = 200.000
102659113051412

500.000*(1-0.2) = 800.000

 

I hope it is clear what I am trying to achieve and you have an idea how to do this?
As an addition it would be perfect if there would be some way to show on a card or on the parameter slicer which product is changed (in the example case somewhere the number 113051410 should show up)

1 ACCEPTED SOLUTION
V-lianl-msft
Community Support
Community Support

Hi @Thraciel ,

 

You can refer to the pbix.

test_0220.PNG

 

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

View solution in original post

3 REPLIES 3
V-lianl-msft
Community Support
Community Support

Hi @Thraciel ,

 

You can refer to the pbix.

test_0220.PNG

 

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

Hi @V-lianl-msft ,

 

thank you for your suggestion but I am not entirely sure that this is what I am looking for as you created a column for the slicer - I would like to use a parameter (which is fully changeable in the report). Otherwise my data would explode if I would create a new line for each possible configuration.

 

But I like the general idea using MIN and MAX to identify the different products, that should work and allows me to show which factor is used for which product to the user. The only downside I can think about right now is that this works just for two products. But for more than that Power BI seems to be the wrong tool.

Hi @Thraciel ,

 

If the problem persists,could you please share sample pbix and the result you expected?(Please mask any sensitive data before uploading)

 

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

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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