Filtering the Row based on Unique String

Hi,

Currently I am trying to create a report based on the issues under epics that contain specific string within the EPIC Name.

I tried using the following on the row:

Aggregate({
Filter([Issue].[Issue].Members,
[Issue].CurrentHierarchyMember.Name matches ‘.test12#.’)
})

and tried using the “Filter by Name” matches test12# however none of them worked.

I would like to only have Epics that contains specific string value (in the above example it will be “test12#”) to show within my rows.

Thanks

Hi,

If you want to filter issues by the substring in their name, we usually recommend using a slightly different regular expression in the filter for matches condition (see the attached image below)

Usually, EPIC Name is a different field in Jira, therefore, please be careful with the requirement.
For Epic Name field [Issue].CurrentHierarchyMember.Name wouldn’t work.
You would use [Issue].CurrentHierarchyMember.get(‘Epic Name’)

Martins / eazyBI support

1 Like

Thank you Martins for the reply

The code worked!
Currently with that filtering it only shows epics on the row however I would like to also show issues that are related to the epics.

How do I get the all the issues that are linked to the filtered epics?

Hi Martins,

Thank you so much for your answer. It worked I am able to filter the epics based on the specific Strings.

I would like to show the completion of the filtered epics (progress based on the issues that are tied to the epic).

Within the Measure Field I created new calculated members:

CASE WHEN
[Measures].[Issues created] > 0
THEN
[Measures].[Issues resolved]
/
[Measures].[Issues created]
END

However no results will show…

Hi,

It has to be due to your calculated members
How do you define “Ordered Statuses” and which is the dimension where you defined it?

Better if you can share the whole report definition exported to JSON

Martins / eazyBI support

Hi,

To show for each epic also their children (related issues to epic) you could use the Epic hierarchy if “Epic Link” is imported.
https://docs.eazybi.com/eazybijira/data-import/data-from-jira-and-apps/jira-software-custom-fields#JiraSoftwarecustomfields-JiraSoftwarecustomfieldsimport

Note that on Epic level epic itself also would be counted when you use Epic level with standart measures (like “Issues created” or “Issues resolved”)

Martins / eazyBI support

Hi Martins,

Thank you for your reply.

“Ordered Statuses” = these are all the statuses but used aggregate function to show them in the order I want to see them (left to right)

Issues by Epic Level does give the child issues however this removes the previous filter of only show epics that contains “.HLS.” and their linked issues (i.e. user stories).

On the columns I would like to see % of completion for those searched epics and number of issues (count) per statuses (i.e. Epicxxx has 3 user stories in To Do, 4 in Progress and 5 in Done)

Thanks,

Albert

Hi @albertkim93

You could set the necessary order for children in “Ordered statuses” member using this approach:

Aggregate({
[Status].[Displayedstatus1],
[Status].[Displayedstatus2],
[Status].[Displayedstatus3]
})

Then it should show same sequence of statuses when expanded.
But please reset the “status” level from the “Status” dimension “All hierarchy level members” menu before you enable the “ordered statuses” member and expand it

If you expect to use the Epic hierarchy and still have the calculated member filtered by HLS then you should save the calculated member in “Epic” hierarchy (see attached image)

Aggregate({
Filter([Issue.Epic].[Epic].Members,
[Issue.Epic].CurrentHierarchyMember.Name matches '. *HLS.* ')
})

And finally, to calculate the % of total, you would need to create a new calculated measure (save it with % format) using the following approach:

CASE WHEN
(
[Measures].[Issues created],
[Status].Defaultmember
)>0
THEN
[Measures].[Issues created]
/
(
[Measures].[Issues created],
[Status].Defaultmember
)
END

Then you can use this measure in your report when “Status” dimension is in columns.

Martins / eazyBI

Thank you for the code
Got it to work as I filtered within the Epic Link dimension instead of issue dimension

1 Like

I am getting the foll. error. Could you please help?

Failed to parse query, try to make query simpler.
Or maybe saved report uses deleted calculated member.
Error message:
All arguments to function ‘{}’ must have same hierarchy.

@Jo_Krish

Please export and share your report definition.
https://docs.eazybi.com/eazybi/analyze-and-visualize/create-reports/export-and-import-report-definitions

Martins / eazyBI

{
“cube_name”: “Issues”,
“cube_reports”: [ {
“name”: “Customer Support time tracking”,
“result_view”: “table”,
“definition”: {“columns”:{“dimensions”:[{“name”:“Measures”,“selected_set”:[“[Measures].[Issues created]”,“[Measures].[Hours spent]”,“[Measures].[CSEpic]”],“members”:[{“depth”:0,“name”:“CSEpic”,“full_name”:“[Measures].[CSEpic]”,“calculated”:true,“drillable”:true,“expanded”:true,“drilled_into”:false,“removed”:true}]}]},“rows”:{“dimensions”:[{“name”:“Project”,“selected_set”:[“[Project].[All Projects]”],“members”:[{“depth”:0,“name”:“All Projects”,“full_name”:“[Project].[All Projects]”,“drillable”:true,“type”:“all”,“expanded”:true,“drilled_into”:false}],“bookmarked_members”:[]},{“name”:“Sprint”,“selected_set”:[“[Sprint].[All Sprints]”],“members”:[],“bookmarked_members”:[]},{“name”:“Assignee”,“selected_set”:[“[Assignee].[All Assignees]”],“members”:[],“bookmarked_members”:[]}]},“pages”:{“dimensions”:[{“name”:“Label”,“selected_set”:[“[Label].[All Labels]”],“members”:[{“depth”:1,“name”:“Support;”,“full_name”:“[Label].[Support;]”}],“bookmarked_members”:[],“current_page_members”:[“[Label].[Support;]”]}]},“options”:{},“view”:{“current”:“table”,“maximized”:false,“table”:{}},“calculated_members”:[]}
} ],
“calculated_members”: [{“name”:“CSEpic”,“dimension”:“Measures”,“formula”:“Aggregate({\nFilter([Issue.Epic].[Epic].Members,\n[Issue.Epic].CurrentHierarchyMember.Name matches '. Support. ')\n})”,“format_string”:“”}]
}

@Jo_Krish
Try this formula for your calculated measure CSEpic.

Sum(
Filter([Issue.Epic].[Epic].Members,
[Issue.Epic].CurrentMember.GetCaption matches '.*Support.8'),
[Measures].[Issues created]
)

Martins / eazyBI

Awesome! That worked like a charm