Advanced Search Results

Sarah Elmer November 2, 2012

Need advice on a filter. Need to have listed tickets that were worked on within the last week by a certain group. This is what I have:

(assignee was in membersOf(IT-Tech) or assignee was techsupport) AND updated >= -1w

The results I am getting are all tickets that have had action taken on them (no matter who took the action) that had been touched in the lifetime (we're talking sometimes a year) of that ticket.

How can I get just tickets that were touched in the last week by the particular group?

3 answers

1 accepted

1 vote
Answer accepted
Norman Abramovitz
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.
November 2, 2012

The query looks correct assuming your group does not include everyone.

Here are some other ways to write the same thing (or close to it). I am doing these JQL from memory so there may be mistakes.

(assignee was in membersOf(IT-Tech) or assignee was techsupport) AND updated >= startOfWeek()


(assignee was techsupport and updated >= startOfWeek()) OR (
assignee was in membersOf(IT-Tech) and updated >= startOfWeek())


Sarah Elmer November 2, 2012

Thought about this set up, but then the date would have to be changed before running the filter to get the correct information. We're trying for it to automatically grab the last 7 days.

Norman Abramovitz
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.
November 2, 2012

The -1w interval is the last seven days. Using startOfWeek() gives the current values for the current week as the week progresses. I guess it depends how you interpet "within the last week".

Sarah Elmer November 2, 2012

Thanks for the clarification. Gave it a try. It's still picking up tickets that were updated within the last week, BUT the users designated have not touched in months. I need to only see the tickets that this group of users actually did action on for that time period (startofweek).

Norman Abramovitz
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.
November 2, 2012

I think we are all thinking of the query incorrectly. Let say, an issue is assigned to you. Five (5) weeks later the issue is still assigned to you and no changes was done. In the fifth week, is still assigned to you. Maybe query is asking who has the assignment this week.

Norman Abramovitz
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.
November 2, 2012

I would try removing the word was and see if your results are any better.

Sarah Elmer November 3, 2012

You are a GENIUS! It worked! Thank you so much!

0 votes
Norman Abramovitz
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.
November 3, 2012

Does this JQL return what you are expecting?

(assignee was in membersOf(IT-Tech) after -1w or assignee was techsupport after -1w) AND updated >= -1w

You should be able to replace -1w with startOfWeek() as well.


Norman Abramovitz
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.
November 3, 2012

The difference between the two queries should be the one without was will give you what is currently assigned to your group and user. The query on this answer is suppose to return issues assigned to your group or user even if they later assigned to a different user.

0 votes
Jobin Kuruvilla [Adaptavist]
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.
November 2, 2012

Your query looks right. Maybe do a full reindexing to see if indexes are out of place?

Sarah Elmer November 2, 2012

Already tried that one. It's still pulling tickets that they had "touched" prior to the date range.

Jobin Kuruvilla [Adaptavist]
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.
November 2, 2012

What is the updated date on those tickets? prior to last 1 week?

Sarah Elmer November 2, 2012

No, it's all tickets in the previous last 7 days.

Jobin Kuruvilla [Adaptavist]
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.
November 2, 2012

Isn't that what you are querying? I am not sure what is the issue here!

Norman Abramovitz
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.
November 2, 2012

I thought the issue was he was getting issues that were not worked on during the last 7 days by people he was not queryed for. If you try

assignee was techsupport after -1w

which should have worked, but I believe I am getting incorrect results on 5.1.7.

Suggest an answer

Log in or Sign up to answer