Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more.
Get startedGrow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.
Hello community I can't calculate a measure that calculates days lost across 2 dates (beginning of the decline and end of the decline).
I have a fact table that shows me all the accidents, the date the accident occurred and the dates of sick leave.
How can I calculate the days lost?
Thanks for the help.
Hi @JoaoSifredo ,
Based on your description,
Please try code as below to create a measure.
My Sample:
The lost days = DATEDIFF(SELECTEDVALUE('Table'[Inicio]),SELECTEDVALUE('Table'[Fim]),DAY)+1
Result is as below.
Please correct me if I misunderstood your needs.
Best Regards,
Yulia Yan
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@v-weiyan1-msft Many thanks for the reply.
It's not the solution I want. I intend to know how many lost days I have each month. We have sick leave that lasts for several months. After applying slicers, I want to know how many days were lost each month. There may be casualties that start on the same day.
User | Count |
---|---|
54 | |
48 | |
19 | |
16 | |
15 |
User | Count |
---|---|
115 | |
42 | |
41 | |
27 | |
22 |