Forum Discussion
calculate % based on multiple criteria
- Anonymous2 years ago
Hi bree_carter
Please try this:
With your data, I create a calcualte column:
Calculated Shift = VAR _sumHours = CALCULATE( SUM('Table'[Hours]), FILTER('Table', 'Table'[Date]=EARLIER('Table'[Date]) && 'Table'[Employee Id]=EARLIER('Table'[Employee Id]) ) ) //Get the sum of the Hours separately RETURN 'Table'[Hours]/_sumHoursSelect the Column(Calculated Shift) > Column tools > Change the Display the values in this column with commas as a thousand separator to 2
The result is as follow:
Best Regards,
Zhengdong Xu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi bree_carter
Please try this:
With your data, I create a calcualte column:
Calculated Shift =
VAR _sumHours = CALCULATE(
SUM('Table'[Hours]),
FILTER('Table',
'Table'[Date]=EARLIER('Table'[Date])
&&
'Table'[Employee Id]=EARLIER('Table'[Employee Id])
)
)
//Get the sum of the Hours separately
RETURN 'Table'[Hours]/_sumHours
Select the Column(Calculated Shift) > Column tools > Change the Display the values in this column with commas as a thousand separator to 2
The result is as follow:
Best Regards,
Zhengdong Xu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
This is PERFECT! Thank you so much. I really appreciate your time and help.