I have the following data:
Table A
Emp_ID, Weekending, Date, Dept_ID, Status, Hrs
Table B
Dept_ID, Dept_Nm, Dept_HOD (relationship: Dept_ID)
I would like to create a matrix table with the following:
Columns: Weekending
Rows: Emp_ID
Value: Using DAX measure if(Status="F",SUM(Hrs)-44,SUM(Hrs)-22)
where the table can be controlled by the Slicers: Weekending, Dept_Nm, Dept_HOD
Any advice on how I can create the DAX measure?
The red box ID are not suppose to be there as they are not in the selected department
SUMX(Table, Table[Hrs] - if(Table[Status]="F", 44, 22))
. But that depends on the underlying data, which would also be useful to see. It might be that you want to sum all the rows per employee and then subtract 44 or 22, but that's not clear from the question. – W.B.