Forum Discussion

aallman's avatar
aallman
Icon for Helper II rankHelper II
1 year ago
Solved

Measure based on Multiple Slicer Selection

Hello! I have a measure to calculate fail rate. Right now it is actually a couple of measures: one counting all the fails, one counting the total items, and a third that does the calculation to turn...
  • Jihwan_Kim's avatar
    1 year ago

    Hi,

    I am not sure if I understood your question correctly, but please try something like below and check whether it works.
    If you are using ALL DAX function in one of your measures, please try using ALLSELECTED DAX function.

     

    ALLSELECTED function (DAX) - DAX | Microsoft Learn

     

    expected result measure: =
    VAR _failcount = [failcount measure]
    VAR _allitemcount =
        CALCULATE ( [itemcount measure], ALLSELECTED () )
    RETURN
        DIVIDE ( _failcount, _allitemcount )