Hi there, I am new to EazyBI and am trying to create a report that has Story name as Rows and then has Number of Subtasks and Subtask status as columns. I have found the following code online that will create a column and then list the status of subtasks separated by a comma.
Calculated measure and code below used to get comma separated list of subtasks:
– generate all sub-task keys list from Sub-task hierarchy
Generate([Issue.Sub-task].[Parent].getMemberByKey(
[Issue].CurrentHierarchyMember.Key).Children,
[Status].[Status].getMemberNameByKey(
[Issue].CurrentHierarchyMember.get(‘Status ID’)
), ‘,’)
I want to have a separate column for each Subtask Status (Testing, To Do etc) with a count of no subtasks with that status but am struggling with the formula. Can anyone help please
Many thanks
Hi @MatthewBuck
You could try creating new calculated measure using this formula:
CASE WHEN
[Issue].CurrentHierarchyMember.level.name = "Parent"
AND
Not IsEmpty([Measures].[Issue sub-task keys])
THEN
Sum(
[Issue].[Issue].GetMembersByKeys(
[Issue.Sub-task].CurrentMember.get('Sub-task keys')
),
[Measures].[Issues created]
)
END
Then add it to report columns in report. Next, use “Drill into” feature on that measure and choose to drill by Status dimension.
Martins / eazyBI
Hi @martins.vanags Thanks for response. I am struggling a bit with this. I have added the calculated measure as suggested and added the Drill Into Feature, however there are no results for the Count of Subtasks by Status
.
Many thanks
Likely you are using a different hierarchy instead of “Issue.Sub-tasks”
try this formula:
CASE WHEN
[Issue].CurrentHierarchyMember.level.name = "Parent"
AND
Not IsEmpty([Measures].[Issue sub-task keys])
THEN
Sum(
[Issue].[Issue].GetMembersByKeys(
[Issue].CurrentHierarchyMember.get('Sub-task keys')
),
[Measures].[Issues created]
)
END
Martins
1 Like
Thanks @martins.vanags - this works