Forum Discussion
Anonymous
7 years agoNot applicable
Adding a Total Column to a Matrix Visual that only sums spcific columns
I have a table that has (simplified) the columns CustID, Action, Date I then have a matrix visual that has Action as Columns, CustID AS Rows and Count(Action) as Values. Now I need an extra column ...
v-yuta-msft
Community Support
7 years agoHi DevOn99,
You you create measures using DAX formula like pattern below:
A = CALCULATE(COUNT(Table1[Action]), FILTER(ALLEXCEPT(Table1, Table1[CustId]), Table1[Action] = "A")) B = CALCULATE(COUNT(Table1[Action]), FILTER(ALLEXCEPT(Table1, Table1[CustId]), Table1[Action] = "B")) C = CALCULATE(COUNT(Table1[Action]), FILTER(ALLEXCEPT(Table1, Table1[CustId]), Table1[Action] = "C")) D = CALCULATE(COUNT(Table1[Action]), FILTER(ALLEXCEPT(Table1, Table1[CustId]), Table1[Action] = "D")) Sum(A, B) = CALCULATE(COUNT(Table1[Action]), FILTER(ALLEXCEPT(Table1, Table1[CustId]), Table1[Action] = "A" || Table1[Action] = "B"))
This result is like this:
Regards,
Jimmy Tao
Anonymous
7 years agoNot applicable
The problem is, that the visual is a matrix and