cancel
Showing results for
Did you mean:
Helper I

## Calculate percentage of Job Cost hours and Overhead hours

I am new to power bi and need some help calculating JC hrs and OH hrs. I have filtered my data and have added calculated columns for Total Hours, JC hrs and OH hrs. As you can see in my matix table above, the Total hrs column shows the total hrs for all cost centers for each employee (each row) and a column total. The JC hrs column shows the total hrs for certain cost centers for each employee (row) and column total and the OH hrs column shows the total hrs for each employee (row) for certain cost centers and the column total hrs. I need to show the % of JC hrs and % OH hrs for each employee (row) and percentage of total hrs (column) based on their total hrs. I tried the formula

% JC Hrs = DIVIDE( SUM(TC_History[Job Cost Hrs]), SUM(TC_History[Total Hrs] )) but as you can see, it does not return the correct values. The first employee should show 1 (100%) % JC hrs but is showing as 31.05.

All help is greatly appreciated.

1 ACCEPTED SOLUTION
Community Support

Did you calculate the values of % JC Hrs using a calculated  column? If so, you need to create a measure. Then the formula is working.

Best Regards,

Xue Ding

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
2 REPLIES 2
Community Support

Did you calculate the values of % JC Hrs using a calculated  column? If so, you need to create a measure. Then the formula is working.

Best Regards,

Xue Ding

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Helper I

Yes I did. thanks for your help. I created the measure and it is working now. Being new to this, a bit confused as to what to use when.

Announcements

#### 2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

#### Microsoft named a Leader in The Forrester Wave

Microsoft received the highest score of any vendor in both the strategy and current offering categories.

#### Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Top Solution Authors
Top Kudoed Authors