Forums

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

Automatic JQL Query

Muhammad Bilal
Contributor
June 5, 2019

Hi,

I have couple of request that needs to be done on our Jira Cloud, let me know please how can i achieve the below points successfully.

1) How to create a JQL filter in order to see the number of incident( Open ticket ) created per week ( Monday to Monday)on the Jira service desk project. Let me know which query i can use to save it in the filter so that i do not have to change it every time, it should update in a way that every time i extract it on the excel it should update the latest week report.

 

2) Is there any way i can use cumulative graph for my Jira service desk project, or may be something similar.

 

Looking forward to hear soon for the help.

 

Thank you

Muhammad Bilal

 

1 answer

1 accepted

0 votes
Answer accepted
Tomas Gustavsson
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.
June 5, 2019

Something like this?

project = xxxxxx and created < startOfWeek(-1)

please check
https://confluence.atlassian.com/jirasoftwarecloud/advanced-searching-functions-reference-764478342.html

Muhammad Bilal
Contributor
June 5, 2019

Hi,

No, i just tried now, this is showing me the entire tickets created for the project,

I was using this before, Project = xyz AND created >= 2019-05-24 AND created <= 2019-05-31

 

But here i need to change every time the date manually, what i want is, it should fetch automatically per week and i go to the dashboard and can extract it to the excel sheet for the report.

Tomas Gustavsson
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.
June 5, 2019

startOfWeek()

Perform searches based on the start of the current week. See For the startOfWeek() function, the result depends upon your locale. For example, in Europe, the first day of the week is generally considered to be Monday, while in the USA, it is considered to be Sunday.

Muhammad Bilal
Contributor
June 5, 2019

startOfWeek() does not work as well, it still shows me all the created request for the entire project. 

Project = xyz AND created <startOfWeek()

 

Thank you

Tomas Gustavsson
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.
June 5, 2019

I will check tomorrow, and get back.

But what i can see from your jql query you shall also add (-1)  see my example above

Muhammad Bilal
Contributor
June 6, 2019

Hi,

 

I have tried both ways, it is really not working. Looking forward for your help.

 

Thank you

Tomas Gustavsson
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.
June 7, 2019

Now i have done some test, and if i write it like this
project = xxxxxx AND created > startOfWeek() i works for me i have changed my statement from
project = xxxxxx and created < startOfWeek(-1)
to 
project = xxxxxx AND created > startOfWeek()  

Muhammad Bilal
Contributor
June 7, 2019

Hi,

Perfect it is working as below:- 

project = xxxxxx AND created > startOfWeek()

 

Just a quick question if i use project = xxxxxx AND created > startOfWeek(-1) it shows me tickets from the date 27th May that is more than a week. So what exactly i need to use here to show me the tickets created all for example every monday till friday. That is 5 days bascially and every monday morning i will extract them on the excel sheet to send it to my clients for the updates. Will this query will automatic updated ? every week

Tomas Gustavsson
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.
June 7, 2019

https://confluence.atlassian.com/jirasoftwarecloud/advanced-searching-functions-reference-764478342.html
Please checkout the information in the link above, that should help you.

also take a look at the endOfWeek funktion 

Examples
Find new issues since the start of this week:
created > startOfWeek()

Find new issues since the start of last week:
created > startOfWeek("-1")

Examples
Find issues due by the end of this week:
due < endOfWeek()

Find issues due by the end of next week:
due < endOfWeek("+1")

Like Muhammad Bilal likes this

Suggest an answer

Log in or Sign up to answer