Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

I have a filter which includes this statement: "status'

Brad Chattillion
Contributor
October 19, 2020

I have a filter which includes this statement:  "status changed to Testing after "2020/09/18"  AND status changed to Testing before "2020/10/17""

 

Is there a way I can return the status changed date in the results?

3 answers

1 accepted

0 votes
Answer accepted
Brant Schroeder
Community Champion
October 19, 2020

While JQL does have historical searching for terms like 'Changed' or 'during', these are limited in how much they can help here because an issue can potentially execute the same transition more than once.  Since JQL is designed to return Jira issues, there is not a way to search for this data in JQL alone, with native Jira at least. 

You could use a 3rd party plugin for Jira like Scriptrunner that might be helpful here.   If you're wanting to create a JQL with this information for the sake of using that filter in a board or dashboard, then I would recommend Scriptrunner.

However if you don't need this as a saved filter, and just want to find the specific times when transitioned happened for an issue, perhaps this approach will help:

For Jira Server users, there is a way to find this data, but you have to run some SQL queries against your database to find clear dates for this kind of transition. Check out the KB https://confluence.atlassian.com/jirakb/how-to-obtain-issue-change-history-from-database-933695139.html It provides some SQL queries you could use to find specific transitions and the times they happen to issues in a Jira Server environment.  This might not help for all use cases, but if you want to find when issues changed a status value, this KB can help with that.

0 votes
Emre Toptancı [OBSS]
Atlassian Partner
November 19, 2020

Hello @Brad Chattillion ,

JQL can only do filtering and the result set will only contain field values on the issue. So getting the transition dates is not easy.

If you want to build a manual solution (that works just by configuration), you can define custom date fields for each of the status dates you are interested in and modify your workflows to update those fields during transitions to relevant statuses. It is a lot of manual and hard to maintain work but it works.

You can build more advanced solutions by processing the issue history that you get via REST API or from the DB directly. You can also build a scripted field for that but all these options require custom development.

 

For a ready built solution that offers great flexibility and details, our team at OBSS built Time in Status app for this exact need. It is available for Jira Server, Cloud and Data Center.

Time in Status allows you to see how much time each issue spent on each status or assigned to each assignee as well as entry/exit dates for all statuses. You can calculate averages and sums of those durations and count grouped by issue fields you select. (For example see the total InProgress time per Epic, or average ToDo time per issuetype). You can also combine statuses into consolidated columns to see metrics like Ticket Age, Cycle Time or Lead Time.

tisCloud_StatusDuration_Report.pngtisCloud_MainPage_Chart_Pie_ExcludeMarked.png

The app calculates its reports using already existing Jira issue histories so when you install the app, you don't need to add anything to your issue workflows and you can get reports on your past issues as well.

The app has Custom calendar support which means you can get your reports based on a 24/7 calendar or your custom business calendar. (This one is important because a 24/7 calendar in most cases shows misleading data. For example an issue created at 16:00 on Friday and was resolved at 09:00 on next Monday seems to stay open for 2,5 days but in terms of business hours, it is only a few hours. You can see this using Time in Status by OBSS.)

Using Time in Status you can:

  • See how much time each issue spent on each status, assignee, user group and also see dates of status transitions.
  • Calculate averages and sums of those durations grouped by issue fields you select. (For example see average InProgress time per project and per issuetype.)
  • Export your data as XLS, XLSX or CSV.
  • Access data via REST API.
  • Visualize data with various chart types.

https://marketplace.atlassian.com/1211756

EmreT

0 votes
Mehmet A _Bloompeak_
Atlassian Partner
November 18, 2020

Hi @Brad Chattillion ,

The info is implicitly available inside Jira and you can get it for each issue over Jira rest api as below. Then you need to parse the response, extract the data and make your calculation.

 issueHistory.png

Or, you can try Marketplace apps which do the parsing and calculation for you. You can try Status Time app developed by our team at Bloompeak. It provides reports on how much time spent on each status as well as status entry dates.

Once you enter your working calendar into the app, it takes your working schedule into account too. That is, "In Progress" time of an issue opened on Friday at 5 PM and closed on Monday at 9 AM, will be a few hours rather than 3 days. It has various other reports like assignee time, status entry dates, average/sum reports(eg. average in progress time per project).

Here is the online demo link, you can see it in action and try.

Hope it helps.

Suggest an answer

Log in or Sign up to answer