Query: Updated bugs assigned to user in last 15 minutes

Dominik Damerow December 15, 2021

I have the following use case:

A customer assigns all Bugs to my user account. But I want the team to get an email each time a bug is assigned to me, or when a bug that is already assigned to me is updated.

I have written the following filter:
issuetype = Bug AND updated >= -15m AND assignee in (myUser)

This is working great for issues that are already assigned to me and then updated.
But sometimes, the customer completely describes a bug and then assigns it to me as the last action.
In this case, the filter doesn't work. Probably because the issue was not assigned to me when it was updated. BUT it is assigned to me after the last update.

How can I rewrite this query to include these issues?

1 answer

1 vote
Alex Koxaras _Relational_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
December 15, 2021

Hi @Dominik Damerow and welcome to the community!

If you want to include also the issues that are assigned to you, why don't you rewrite your JQL like:

issuetype = Bug AND (updated >= -15m AND assignee in (myUser)) OR assignee = myUser
Dominik Damerow December 15, 2021

As far as I can see, this would lead to a different result.
It would also include all issues assigned to me at any time.
Which means the mail would include a huge number of issues of no relevance.
Does

assignee in (myUser)

differ from
assignee = myUser
in the results? I would not expect it to differ, since it is a sql like query language.

Alex Koxaras _Relational_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
December 15, 2021

So what are your business requirements?

  1. See all bugs assigned to you and updated within the last 15 minutes
  2. ?
Dominik Damerow December 15, 2021

My requirements are:

1. See all bugs that were assigned to me - and have been updated in the last 15 minutes

2. See all bugs that were updated in the last 15 minutes by changing the assignee to me

My query fulfills requirement 1, but does not fulfill requirement 2.

Suggest an answer

Log in or Sign up to answer