Forum Discussion

Naveen29's avatar
Naveen29
Helper II
4 years ago
Solved

DAX help

Need help on the below scenerio: How to write a DAX? actual table:   Category Value A 10 B 20 C 30   Out put expecting in the dashboard:   Category Value % A A/C 3...
  • smpa01's avatar
    4 years ago

    Naveen29  try this measure

    Measure =
    VAR _sum =
        DIVIDE (
            CALCULATE ( SUM ( t3[Value] ), FILTER ( t3, t3[Category] <> "C" ) ),
            CALCULATE ( SUM ( t3[Value] ), FILTER ( ALL ( t3 ), t3[Category] = "C" ) )
        )
    RETURN
        _sum