Power Bi - Count Number of Employees who has worked more than 38 and less than 56 hours per week

rubz71

New Member
Joined
Aug 13, 2013
Messages
36
Hi All,

I need a bit of help witht the below formula.
I am trying to count number of employess who has worked more than 38 hours and less than 56 hours per week.
I also have a date table where i have a week number column and connected with employee table with the date column.



Measure = CALCULATE(
DISTINCTCOUNT(Master_data[Employee Num]),
FILTER(Master_data,Master_data[Hours Worked]>38 && Master_data[Hours Worked]<56))

This is the base table. week number for the month of March 22 for a selected location.
Rubal_Islam_0-1648593577483.png

However as soon as i bring the measure in, it becomes blank. it is for an individual week or for all week selected in the date slicer.
1648605613078.png
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
I guess you might need to add a calendar logic in your filter, where master data date matches calendar date.
 
Upvote 0

Forum statistics

Threads
1,215,069
Messages
6,122,953
Members
449,095
Latest member
nmaske

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top