Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
What i have is following data model.
On a certain selected date i have a personnelbudget (field BudgetFTE in vwBudget) and some employees that are working within a company on that data (field No_FTE in vwBezetting)
Now i want to display sum(BudgetFTE - sum(No_FTE) where the difference is > 0 and sum(BudgetFTE - sum(No_FTE) where the difference < 0 in different columns.
This works on level but the total is not there or is incorrect.
How can i calculate the correct total per column?
See below
What is happening here is that DAX does not compute the 'total' by adding the values in the columns, the measures that are giving you the values in the columns are just executed again for the cells in the "total" row, but they do not have the filter context that includes the values in the columns that they need to calculate correctly.
You might be able to fix this by just using SUMX instead of SUM.
SUMX is an interator that will interate over all the lines in the current filter context. When the measure is executing in the "total" row it will have a filter context that includes all the rows visible in the current filter context. So it should total up all their values correctly.
When the measure is executing in one of the rows of the table, its filter context only includes the values for that row so the values it calculates reflect only that row.
Help when you know. Ask when you don't!
User | Count |
---|---|
47 | |
26 | |
22 | |
17 | |
15 |
User | Count |
---|---|
55 | |
34 | |
18 | |
17 | |
15 |