Forums

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

Query for all issues un-closed in the prior week

AC August 1, 2019

[Editing as I mistyped my original question]

Hi,

I'm trying to put together a query for finding all issues that were still not closed in the prior week.  This is part of a dashboard where we are trying to show new issues/unclosed issues/closed issues on a week by week comparison.

This is what I've been able to come up with, but the problem is that it also leaves out issues created in the weeks prior but closed in this current week:

issuetype = Bug AND status != closed AND created < startOfWeek()

I'm not using the resolved status which has a date -- the reason we don't want to use resolved date is we are tracking when the defect reporter closes the ticket, which could overlap to the next week if the issue is marked as resolved on a Friday.  Is there a closed status date field to query?

thanks for any advice!

3 answers

0 votes
Payne
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 2, 2019

In your edited description you state:

... the problem is that it also leaves out issues created in the weeks prior but closed in this current week:

issuetype = Bug AND status != closed AND created < startOfWeek()

Issues closed in the current week should not show, as you have status != closed.

Can you explain a bit more?

AC August 2, 2019

I have to find the ticket that was causing this to not work, but I remember running this query and the search results left out an issue that was closed this current week since they are marked as closed now, but in the prior week, they were still open.

0 votes
Payne
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 1, 2019

This should work:

status changed to closed after startOfWeek(-1) and not status changed to closed after startOfWeek()

AC August 1, 2019

[Editing my reply...I thought it worked when I responded but then when I went back to look I realized it was the wrong results...I'm not doing well today...]

Thanks for the tip!

But I just realized I asked the wrong question. I've been working on multiple filters and typo'd what I intended to ask (which may be why the query I posted really doesn't match my question...)

My actual question is, I'm looking for issues were NOT closed as of the prior week.  I tried updating your suggestion but my query results it all issues closed during the prior week.

not status changed to closed after endOfWeek(-1) and not status changed to closed after startOfWeek() AND status changed to closed after StartOfWeek(-1)

Apologies for my lack of understanding the queries!

0 votes
Randy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 1, 2019

Do you set resolution when the problem is fixed or when the reporter accepts the fix?

use the following pattern for checking in the previous week time period:

type=Bug and resolved >= startOfWeek(-7) and resolved <= startOfWeek()
AC August 1, 2019

Hi Randy, thanks for the response. The resolved status is set by the QA or development team, but the ticket closure status is set by when the issue reporter accepts the fix -- which can be from other business team members, which is why we want to track it separately.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events