Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.
Hi all,
I want to use the Microsoft Power BI template for Project for the Web to follow up on Project Management tasks. A lot of handy functionality out of the box, but there are some frustrations as well - the biggest one being that all tasks are listed equally in the report regardless of parent/sub-level, sorted either alphabetically, by start date, or something else. I would rather like users to view the task hierarchy, so that tasks that belong together are shown side by side.
In Project for the Web, sub tasks are neatly indented, and it is possible to show Disposition numbers (picture below) for relationships between parent tasks and sub tasks (up to 10 levels). My issue is that the Disposition number-data does not seem to be available via the same data import from Dataverse (I have checked many tables, but I cannot say I have the full overview - please let me know if I have missed something).
So, how can this be recreated with the help from parent-child relationships and indexation?
The following data represents my inputs from Project for the Web, my efforts to extract the relationships, as well as my desired outcome. In reality, I have 8 different projects with approximately 20-150 tasks and subtasks to follow up in each of them.
From Project for the Web (not Project Online) via Dataverse | Calculations | Desired outcome | ||||||||
Index | Project ID | Task ID | Parent Task ID | Outline level | Task Hierarchy | Level 1 | Level 2 | Level 3 | Level 4 | Disposition nr |
1 | A | T1 | 1 | T1 | T1 | A.1 | ||||
2 | A | T2 | T1 | 2 | T1|T2 | T1 | T2 | A.1.1 | ||
3 | A | T3 | T1 | 2 | T1|T3 | T1 | T3 | A.1.2 | ||
4 | A | T4 | T3 | 3 | T1|T3|T4 | T1 | T3 | T4 | A.1.2.1 | |
5 | A | T5 | T4 | 4 | T1|T3|T4|T5 | T1 | T3 | T4 | T5 | A.1.2.1.1 |
6 | A | T6 | T4 | 4 | T1|T3|T4|T6 | T1 | T3 | T4 | T6 | A.1.2.1.2 |
7 | A | T7 | T4 | 4 | T1|T3|T4|T7 | T1 | T3 | T4 | T7 | A.1.2.1.3 |
8 | A | T8 | 1 | T8 | T8 | A.2 | ||||
9 | A | T9 | T8 | 2 | T8|T9 | T8 | T9 | A.2.1 | ||
1 | B | T10 | 1 | T10 | T10 | B.1 | ||||
2 | B | T11 | T10 | 2 | T10|T11 | T10 | T11 | B.1.1 | ||
3 | B | T12 | 1 | T12 | T12 | B.2 |
My issue now is to get the numbers for each level right, meaning that all rows indexed 1-7 are A.1.x, rows indexed 3-7 are A.1.2.x, etc. From there, I would combine these to a Disposition number to sort by in report tables. Ideally I would like the Disposition number in the report to be equal to the Disposition number in Project for the Web, but I am not sure if that is possible.
I would really appreciate guidance on how to create the Disposition numbers allowing me to sort such that related tasks can be shown next to each other in the report.
Solved! Go to Solution.
Disposition Number =
VAR _id = 'Table'[Project ID]
VAR _idx = 'Table'[Index]
VAR _length =
PATHLENGTH ( 'Table'[Path] )
VAR _p = 'Table'[Path]
VAR _tbl =
FILTER ( 'Table', 'Table'[Project ID] = _id )
RETURN
_id & "."
& CONCATENATEX (
GENERATESERIES ( 1, _length ),
COUNTROWS (
FILTER (
_tbl,
VAR _len =
PATHLENGTH ( 'Table'[Path] )
VAR _pid =
PATHITEM ( _p, [Value] - 1 )
RETURN
_len = [Value]
&& 'Table'[Index] <= _idx
&& IF ( [Value] = 1, 1, 'Table'[Parent Task ID] = _pid )
)
),
"."
)
Disposition Number =
VAR _id = 'Table'[Project ID]
VAR _idx = 'Table'[Index]
VAR _length =
PATHLENGTH ( 'Table'[Path] )
VAR _p = 'Table'[Path]
VAR _tbl =
FILTER ( 'Table', 'Table'[Project ID] = _id )
RETURN
_id & "."
& CONCATENATEX (
GENERATESERIES ( 1, _length ),
COUNTROWS (
FILTER (
_tbl,
VAR _len =
PATHLENGTH ( 'Table'[Path] )
VAR _pid =
PATHITEM ( _p, [Value] - 1 )
RETURN
_len = [Value]
&& 'Table'[Index] <= _idx
&& IF ( [Value] = 1, 1, 'Table'[Parent Task ID] = _pid )
)
),
"."
)
Thank you so much, @wdx223_Daniel!
This is just what I was looking for. It works perfect!
Check out the November 2023 Power BI update to learn about new features.
Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.