Forum Discussion
Dax measure formula
- Anonymous1 year ago
Thanks for the reply from HarshSathwara19 , Kedar_Pande and rajendraongole1 , please allow me to provide another insight:
Hi nesrinehal20 ,You can use the allselected() function to dynamically get the values after filtering.
ALLSELECTED function (DAX) - DAX | Microsoft Learn
The ALLSELECTED function gets the context that represents all rows and columns in the query, while keeping explicit filters and contexts other than row and column filters. This function can be used to obtain visual totals in queries.
Here are the steps you can follow:
1. Create measure.
Measure = var _allsum= SUMX(ALLSELECTED('Table'),[open time item]) return DIVIDE( SUM('Table'[open time item]),_allsum)2. Result:
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi nesrinehal20 - Create a measure to calculate the total opening time for poste = bs and center = gias1
Total Opening Time =
CALCULATE(
SUM('Table'[open time item]),
'Table'[poste] = "bs",
'Table'[center] = "gias1"
)
Create another measure to calculate the key to_bs for each row
Key to_bs =
DIVIDE(
SUM('Table'[open time item]),
[Total Opening Time]
)
In the Fields pane, select the Key to_bs measure.
Under the Modeling tab, change the format to Percentage.
Hope this works, please check.
doesn't work, 100% cle for all the articles