Forums

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

JQL to find tickets created "yesterday" / last working day

Deleted user August 19, 2021

How do I write a JQL query to find tickets that have been created "yesterday", but ignore weekends? So essentially find tickets that have been created since the last working day.

Examples:

  • if today is Thursday, find all tickets created since Wednesday
  • if today is Saturday, find all tickets created since Friday
  • if today is Sunday, find all tickets created since Friday
  • if today is Monday, find all tickets created since Friday

2 answers

1 accepted

1 vote
Answer accepted
Bill Sheboy
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 19, 2021

Hi @[deleted] 

Short answer: you cannot do that with out-of-the-box JQL features for an arbitrary starting day

Work-around: you could use specific, saved filters and subscriptions to get what you want.

Please take a look at this post and documentation for more details:

Best regards,
Bill

Deleted user August 19, 2021

Hi @Bill Sheboy,

thanks for the help. Unfortunately, it's not really what I need. I was looking for a query because I was interest in the number of tickets for statistical reasons:

  • How many tickets were created since the last working day
  • How many tickets were resolved since the last working day

Do you know if there's a way to get that information? I prefer not to use filter subscriptions and then having to write a script that parses the emails each day.

Thanks,

Sabine

Bill Sheboy
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 20, 2021

Thanks for explaining that. 

If you plan to do a lot of reporting for this, it probably would be best to do it outside of Jira, either by exporting or using the Excel or Google Sheets add-ins.  Then you could easily do the math in that tool and chart/measure the results.

If you would still prefer to get one number every day, you could:

  • build an automation rule to perform the count
  • buy a marketplace addon for JQL to help with the query
Deleted user August 22, 2021

Ok, thanks for the suggestion. I will dig into ScriptRunner.

zacharoula_brinia
Contributor
June 14, 2023

Hello,

How is yesterday or the last working day in JQL?

Thank you.

0 votes
Sebastian Krzewiński
Community Champion
August 20, 2021

Hi @[deleted] 

Did you try created vs resolved gadget on dashboard? This gadget shows how many issues were created and resolved per day/week/month.

Deleted user August 22, 2021

Yes, unfortunately, with this gadget, you only get a graphical representation, but then as far as I can see you can't get the numbers unless you somehow "parse" the chart?

Sebastian Krzewiński
Community Champion
August 22, 2021

But when you put cursor on it it shows numbers. Please try this.

Deleted user August 22, 2021

Yes, I know this - that is what I meant by writing "parse". To automate this, I would have to simulate a mouse hover to be able to retrieve the numbers.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events