List all values of a custom field (multiple selection list) and its related issues (+childs)

Hey dear Community,
I hope you can help me setting up a report with eazyBI for Jira.

Context
We have a custom field, that is essentially is a multi-select list with categories. Those categories can be assigned to Epics and Initiatives. Usually, if an Epic has categories assigned to it the Initiative receives those as well as an Initiative is the Parent of an Epic in our context.

The problem
We’re trying to build a report based on all values of the categories to visualize which categories have been assigned and which are still empty. So we have a Custom field and Issue relationship (many to many).

Our current problem is that we only get the values that have something assigned to it and not the empty values. And the second Problem is that we do not know how we should build up the measure of child related to an assigned Epic with these categories.

Looking forward to your great advises

@gerda.grantina can you support me here as well. Highly appreciate your support :pray:

Hi @felix.geelhaar,

The eazyBI only creates dimension members once encountered during the data import.
If there is a category that is not used yet, the eazyBI would not create the related dimension member.

Generally, the report context relates to the measures for the lowest hierarchy level of the dimension. So if you have Category in report pages then measures would return the value of children issues having this category.

If you want to filter child issues by the category of their ancestor Epic or Initiative, you might inherit that value through the dimension and have new dimensions like “Epic Category” or “Initiative Category”.
Please read more about inherited dimensions here - JavaScript calculated custom fields.

An alternative option, if you want to include an issue which itself or any of its parents was assigned a specific category, might be a conditional check upon the issue and its ancestors.
The expression might then be as follows.

CASE WHEN
 (
--issue itself relates to context 
 [Measures].[Issues created]
 +
--Epic parent of issue relates to Category
 DefaultContext(
   ([Issue].[Issue].GetMemberByKey(
     Ancestor(
      [Issue].CurrentHierarchyMember,
      [Issue].CurrentHierarchy.Level("Epic")).Key),
   [Category].CurrentHierarchyMember,
   [Measures].[Issues created])
 )
 +
--Initiative grandparent relates to Category
 DefaultContext(
   ([Issue].[Issue].GetMemberByKey(
     Ancestor(
      [Issue].CurrentHierarchyMember,
      [Issue].CurrentHierarchy.Level("Initiative")).Key),
   [Category].CurrentHierarchyMember,
   [Measures].[Issues created])
 )
 )>0
THEN
 (
--resetting the Category dimension as its relevance already checked
  [Category].CurrentHierarchy.DefaultMember,
--the actual measure for issue
  [Measures].[Issues created])
END

This uses the DefaultContext() function and looks at issue Ancestor() as a separate issue in default issue hierarchy.

Regards,
Oskars / support@eazyBI.com

1 Like

Thanks @oskars.laganovskis
this resolved it.

I think, it was a bit difficult to get my head around the DefaultContext Option, and your example helped a lot.

Thanks a ton.
Cheers,
Felix

1 Like