# How to count issues that had ever been reopened

**URL:** <https://community.eazybi.com/t/how-to-count-issues-that-had-ever-been-reopened/3466>\
**Category:** Questions & Answers\
**Tags:** history, jira\
**Created:** [January 14, 2020, 9:30am UTC](https://community.eazybi.com/t/how-to-count-issues-that-had-ever-been-reopened/3466 "2020-01-14T09:30:15Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![liu.jingjing](https://community.eazybi.com/letter_avatar_proxy/v4/letter/l/f07891/32.png) [@liu.jingjing](https://community.eazybi.com/u/liu.jingjing)\
**Post date:** [January 14, 2020, 9:30am UTC](https://community.eazybi.com/t/how-to-count-issues-that-had-ever-been-reopened/3466/1 "2020-01-14T09:30:16Z")

</div>

Hi ,  
I want to create a measure to count issues which meet following two conditions:  
1、the issue had ever been reopened;  
2、the issue’s current resolution is “fixed” 、 “unresolved” or “none”

I am looking forward for your reply.  
Thanks in davance!

---

<div class="post-metadata">

**Author:** ![gerda.grantina](https://community.eazybi.com/user_avatar/community.eazybi.com/gerda.grantina/32/1994_2.png) [@gerda.grantina](https://community.eazybi.com/u/gerda.grantina)\
**Post date:** [February 7, 2020, 2:39pm UTC](https://community.eazybi.com/t/how-to-count-issues-that-had-ever-been-reopened/3466/2 "2020-02-07T14:39:12Z")

</div>

Hi @liu.jingjing,  
To see which issues have been Reopened, you need to use [**Issue history change measures**](https://docs.eazybi.com/eazybijira/data-import/jira-issues-import/import-issue-change-history) **.**

There are two ways how you can check if the issue **was Reopened**.  
1.If you have a **specific status for reopened issues** , then by using that you can create this [calculated measure](https://docs.eazybi.com/eazybijira/analyze-and-visualize/calculated-measures-and-members) in **Measure** dimension that checks issues that have been **transitioned to** it:

```
    (
    [Transition Status].[Reopened],
    [Measures].[Transitions to status issues count]
    )

```

2.Or if you count all **issues that have done some specific transitions in the workflow** as reopened then use this formula:  
a) For several possible transitions, create an aggregate member **Reopened** in the **Transition** dimension.

```
    Aggregate({
    [Transition].[Done => Open],
    [Transition].[Done => In Progress],
    [Transition].[Done => Waiting for support]
    })

```

b) Then use this aggregate [in this calculated measure](https://docs.eazybi.com/eazybijira/analyze-and-visualize/calculated-measures-and-members) in **Measure** dimension to count how many issues were reopened:

```
(
[Transition].[Reopened],
[Measures].[Transitions from status issues count] 
)

```

(Don’t forget to change the value in **Transition** and **Transition status** dimensions to the ones that are relevant to your workflow)

3.To check **the current resolution** for those issues will be a little bit more problematic as the dimension **Resolution** works together with historical measures, so in this case, this dimension will check resolution at the moment when the transition was done. If you have statuses that have a similar meaning to your resolutions that you can use the **Status** dimension as it indicates **the current status** of the issue.

 ![Reopened](https://community.eazybi.com/uploads/default/original/2X/5/57b7261b66787cb43ae95aec4004868702a6987d.png)  
4.But if you need **current resolution** and you can’t use the status dimension that the formula goes a bit trickier.  
(you can choose which of the reopen measures mentioned above suits to your case and change it in formula accordingly)

```
NonZero(
Count(
Filter(
Descendants([Issue].CurrentMember, [Issue].[Issue]),
-- filters issues where resolution is Done or unresolved
[Measures].[Issue resolution] MATCHES 'Done|.*unresolved.*'
AND
-- filters issues that are created, time dimension is ignored, if this measure is used with time dimension then it will be orderd by transition date
([Measures].[Issues created], [Time].CurrentHierarchy.DefaultMember) > 0 
AND
-- filters issues that has been reopened, this measure is used for sorting issues with Time dimension
([Transition Status].[Reopened],
[Measures].[Transitions to status issues count]) > 0 
)
)
)

```

best,  
Gerda // [support@eazybi.com](mailto:support@eazybi.com)
