Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreWe've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
Hi,
I have a table where there is id. next chained id Start date, End date.
What I'm trying to achieve is to calculate the total duration of the work leaves but I'm not able to come up with the solution how the "edge case" is recognized that it is the last workleave that is part of the whole chain and the bolded "False" should also be True
This is my best effor (calculated column
Solved! Go to Solution.
Read about the PATH functions.
Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...
Please show the expected outcome based on the sample data you provided.
https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523
Read about the PATH functions.
Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...
Please show the expected outcome based on the sample data you provided.
https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523
Access is denied.
I got a bit forward with this and got the dax to calculate the total duration of the chained work leaves
| Workleave.id | Previouschainedworkleave.id | path | Duration | Total duration |
| 111 | 111 | 1 | 1 | |
| 222 | 111 | 111 | 222 | 1 | 2 |
| 333 | 222 | 111|222|333 | 1 | 3 |
| 444 | 444 | 1 | 1 | |
| 555 | 555 | 1 | 1 |
but the correct end result would be
| Workleave.id | Previouschainedworkleave.id | path | Duration | Total duration |
| 111 | 111 | 1 | 3 | |
| 222 | 111 | 111 | 222 | 1 | 0 |
| 333 | 222 | 111|222|333 | 1 | 0 |
| 444 | 444 | 1 | 1 | |
| 555 | 555 | 1 | 1 |
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 55 | |
| 34 | |
| 31 | |
| 19 | |
| 17 |
| User | Count |
|---|---|
| 74 | |
| 71 | |
| 38 | |
| 35 | |
| 25 |