Forums

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

JQL Function

VikasBasra February 24, 2015

How do we write a JQL function which will fetch the issues based on issues opened\created one day before. Ouq requirement is when the function runs on Monday it should extract data for Friday , Sat, Sun. When the same query is executed on Tuesday it should only pull data for Monday .

3 answers

1 accepted

1 vote
Answer accepted
Udo Brand
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.
February 24, 2015

You can achieve this with following query

(created > startOfDay(-1d) and created < startOfDay()) or (created >startOfDay(-3d) and created < startOfDay() and created < startOfWeek())

The first bracket contains all issues created the day before, the second is valid for all issues created in the last three days and before the week started. Note, depending where you are the week starts at different days (Some start with Monday some with Sunday). If Sunday is the first day use startofWeek(1d)

0 votes
VikasBasra March 2, 2015

Thaks Udo. It works.

0 votes
Steven F Behnke
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.
February 24, 2015

This is a duplicate of https://answers.atlassian.com/questions/38644

Hmm, well I'm not sure you can pull Friday, Saturday, Sunday automatically but the easiest way to grab issues based on created date is so:

createdDate >= -1d
createdDate >= -72h

Or something of this nature.

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, confluence, loom, atlassian intelligence, ai notes, ai-powered meeting notes, atlassian community events, ace, confluence ai, loom ai integration, ai note-taking, atlassian ai features, team '25, atlassian live learning, confluence automation

Unlock AI-powered meeting notes: Join our live learning session! 📹

Did you catch the news at Team ‘25? With Loom, Confluence, Atlassian Intelligence, & even Jira 👀, you won’t have to worry about taking meeting notes again… unless you want to. Join us to explore the beta & discover a new way to boost meeting productivity.

Register today!
AUG Leaders

Atlassian Community Events