Counting stories that fulfill a condition

Dear community,

I want to create a metric of “Resolved Small Stories” vs. “Resolved Large Stories” over Time. The trigger would be that “Hours spent with Sub-tasks” is greater than 20 hours.

I already succeeded in creating a Measure that attributes Stories correctly when I include the Issue-Dimension into my report (see below). But I don’t want this information in the final report - a simple list would be sufficient:

Team A
            Small Stories      Large Stories
2020-01     40                 10
2020-02     30                 15
2020-03     35                 10
2020-04     40                  5

How can I achieve that the measure is aggregated when I leave out the Issue Dimension?

My measure currently is

    ([Measures].[Issues resolved], [Issue Type].[Story]) > 0
    ([Measures].[Hours spent with sub-tasks], [Issue Type].[Story]) < 20),
    [Measures].[Issues resolved]

With issue dimension I get a result like this:

Please do not tell me that I have to use the Descendants-Function as this will certainly put our instance into timeouts…

Kind regards,

Hi @thv,
If you want to avoid using descendants-function (as indeed, that is missing in your formula), then you can check custom intervals and create Hours spent as one -

The Javascript code that you need to use in eazyBI advanced settings would be like this:

name = "Hours spent interval"
data_type = "integer"
dimension = true
javascript_code = '''
if (issue.fields.timespent) {
  issue.fields.customfield_hoursspent_interval = Math.floor(issue.fields.timespent/60/60);
time_unit = "hours"
time_interval = "duration"
intervals = "/10"
interval_unit = "hours"

You can change the interval accordingly to your needs.
Then using them in tuples, you will be able to calculate resolved small and large stories.

Gerda //