I have to analyse the time each member of our IT group spends on solving Tickets. While the first column displays the total for each member on all Categories (this is the one I get correctly), the next columns should display the total of time each member spent on the different Categories.
member TotalTime Tickets_ERP Tickets_Report Tickets_SQL Tickets_Other
-----------------------------------------------------------------------------
John 80 15 0 55 10
Mary 120 85 35 0 0
Peter 90 25 60 0 5
I created the measure
TotalTime = SUM(Tickets[workingTimeMinutes])
and dragged members and TotalTime into a Matrix. So far so good. How do I need to define the SubTotals for the different Categories? I can’t make it work.
This is what I tried:
Tickets_ERP = CALCULATE(SUM(Tickets[workingTimeMinutes]),Tickets[Category]="ERP")
I kind of understand that I need to build a SUMX on row basis where I sum up based on the condition, but can’t make the syntax work.
ChatGPT helped me to get the solution:
Tickets_ERP = CALCULATE(SUM(Tickets[workingTimeMinutes]),Filter(Tickets,Tickets[Category]="ERP"))
2