Forum Discussion
Column Total not taking into account Filtered Field
Hi there,
I'm having an issue with the column total in Power BI not showing correctly.
I have a table of all staff and their department/SBU within the company, in some cases, staff can move between different department/SBU as internal transfer. Their timesheet will be under 2 different SBUs during the year of transfer.
I can see the time has been split out correctly under the correct SBU the staff belongs to at the time, however the column total shows the same total number of hours the staff entered but did not split it out between the 2 SBUs. Would any of you have a solution to this issue?
I did try using My Total = CALCULATE(SUM('[Staff Hours]'),ALLEXCEPT('Master Staff','Master Staff'[SBU]) but it didn't work.
Many thanks in advance!
Vivian
5 Replies
- VvelardeCommunity Champion
- buiniaFrequent Visitor
There is no dax to [Staff Hours], it is just timesheet (daily hours) which have been loaded by staff members.
The tables/fields involved in this:
1. Staff Department Master - [Staff Name] - [SBU] - [Month]
2. Staff Master - unique [Staff Name]
3. SBU Master - unique [SBU]
4. Staff Timesheet - [Staff Name] - [Staff Hours] - [Month]
All the master tables are related Many to One - Cross filter Both direction, and they are related to the Staff Timesheet by Many to One - Single cross filter.
Thanks
- v-micsh-msftMicrosoft Employee
Hi buinia,
I suspect this should be related with the data table.
Under the table where [Staff Hours] stated in, we need a column to mark the SBU, this should have Matrix Visual to the show the correct total number.
By the way, would you please share a screenshot of the relationship View in Power BI desktop regarding your tables? Only following the data you shared is a little for me to figure out the relationship between those tables.
Regards