CALCULATE modifiers ALLEXCEPT & VALUES - VimalKumarChaturvedi/PowerBI GitHub Wiki

PowerBI : CALCULATE modifiers ALLEXCEPT & VALUES !

We want to see % of revenue that each product brings among the group it belongs and not on the all the revenue. If we want to see % of revenue among all the revenue, we would be using the ALL modifier to CALCULATE. Following result can be obtained in two ways

  1. Using ALLEXCEPT
  2. Using VALUES

Using ALLEXCEPT:

Sales Allexcept = CALCULATE( [revenue], ALLEXCEPT('Product', 'Product'[Group]) )

Using VALUES

Sales VALUES = CALCULATE( [revenue], ALL('Product'), VALUES( 'Product'[Group]) )

To Get the Percentage

%Prod Sales in Group = DIVIDE([revenue], [sales Allexcept])