Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hello,
I'm a new user and I saw that you helped a lot of people
Could you please help me out with my problem?
I have an employee database and I would like to have a my visual report showing FTE per month.
On the database, I have start and end date and FTE per employee.
I have created a Table Date.
My current code is the following:
Hi @Anonymous ,
How do you calculate the the middle of the month? If it is to take the middle value for all working days of the month, please try the following formula:
FTE Actual =
VAR median_date =
ROUND (
CALCULATE (
MEDIAN ( 'Table Dates'[DateNum] ),
KEEPFILTERS ( 'Table Dates'[IsWorkingDay] = 1 )
),
0
)
VAR Month_middle =
CALCULATE (
MIN ( 'Table Dates'[Date] ),
FILTER ( 'Table Dates', 'Table Dates'[DateNum] = median_date )
)
RETURN
CALCULATE (
SUM ( 'FTE database'[FTE] ),
FILTER (
VALUES ( 'FTE database'[Hire Date] ),
'FTE database'[Hire Date] <= Month_middle
),
FILTER (
VALUES ( 'FTE database'[Termination Date] ),
OR (
'FTE database'[Termination Date] >= Month_middle,
ISBLANK ( 'FTE database'[Termination Date] )
)
)
)
If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.
Best Regards,
Winniz
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi Winniz,
thanks for your help,
I miss just the precision when someone starts or ends during the month, it is rounded to 1, while the FTE should be prorated to the working days per month.
In this visual, the start date is May 19 2021 and termination is February 28 2022.
In excel the formula I used was quite complex.
If you have a kind of solution, it would be great
Thanks,
regds
Yen
Hi @Anonymous ,
Has your problem been solved?
If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.
Best Regards,
Winniz
Hi @Anonymous ,
Please try the following formula:
SumFTE = SUM ( 'FTE database'[FTE] )WorkingDayDiff =
CALCULATE (
SUMX (
VALUES ( 'FTE database'[ID] ),
(
CALCULATE (
COUNTROWS ( 'Table Dates' ),
FILTER (
'Table Dates',
'Table Dates'[Date]
>= MAX ( MIN ( 'FTE database'[Hire Date] ), MIN ( 'Table Dates'[Date] ) )
&& 'Table Dates'[Date]
<= IF (
ISBLANK ( MAX ( 'FTE database'[Termination Date] ) ),
MAX ( 'Table Dates'[Date] ),
MIN ( MAX ( 'FTE database'[Termination Date] ), MAX ( 'Table Dates'[Date] ) )
)
)
)
/ COUNT ( 'Table Dates'[Date] )
)
),
'Table Dates'[IsWorkingDay] = 1,
FILTER (
'FTE database',
'FTE database'[Hire Date] <= MAX ( 'Table Dates'[Date] )
&& OR (
'FTE database'[Termination Date] >= MIN ( 'Table Dates'[Date] ),
ISBLANK ( 'FTE database'[Termination Date] )
)
)
)FTE Actual =
SUMX ( VALUES ( 'FTE database'[ID] ), [SumFTE] * [WorkingDayDiff] )
Best Regards,
Winniz
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Usually you indicate working days in the calendar table in your data model. You have calendar table, right?
Hi,
Yes, I'm using a Table of Dates like this:
Wouldn't you then have to prorate this for everybody else too? How do you know if someone may or may not leave before the end of the month?
You will likely have to calculate the FTE per day. (What if they leave before noon? 🙂 )
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
Check out the November 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 59 | |
| 43 | |
| 42 | |
| 23 | |
| 17 |
| User | Count |
|---|---|
| 190 | |
| 122 | |
| 96 | |
| 66 | |
| 47 |