Forum Discussion

angevin17's avatar
angevin17
Microsoft Employee
5 years ago
Solved

Using a measure with filtered data

Hello,   I have a measure that adds up a column and then divides each row in that column by the total of the column (calculating percentage). However, when I filter by a different column, the origi...
  • Jihwan_Kim's avatar
    5 years ago

     

    Percent measure : =
    VAR _allcount =
    CALCULATE ( SUM ( Data[Count] ), REMOVEFILTERS ( Offers[OfferName] ) )
    VAR _count =
    SUM ( Data[Count] )
    VAR _result =
    DIVIDE ( _count, _allcount )
    RETURN
    _result

     

     

    Link to the sample pbix file