How Can I write JQL for creation time between timestamp?

Nam Dong Yeon March 6, 2024

Hi all, I want to filter the ticket which are created between Night time for the whole year?

Such as, 

Date : 2023-01-01 ~ 2023-12-31

Ticket Created Timestamp : 18:00 ~ Next day 08:00

Can I get that data? 

I used the startOfDay but I can only get one day data, I need to get whole year.

Please help me!

Thanks in advance!

 

2 answers

0 votes
Asmath Basha S
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.
March 7, 2024

Hi @Nam Dong Yeon ,

In Jira you can't filter the tickets for a specific time for the last 1year. Only by specifying each day separately you can find the tickets created for 1day.

But unfortunately this feature is not available in JQL.

0 votes
Alan Stephenson
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.
March 6, 2024

Hi

you can search for that JQL function in google or in the jira documentation. I use startOfDay() or startOfYear() all the time. 

example:

project=xyz and createdDate < startOfYear() 

will give you all created issues less than the start of the current year. You can add values in the ( ) like startOfYear(-2) will subtract to 2years ago.

There are many functions

- startOfMonth()

- startOfWeek()

there is also functions for endOfDay, etc.

I’ll try and find the confluence page that outlines all.

 

-alan

Nam Dong Yeon March 6, 2024

I think my question is different with ur answer.

My means that I want to get all ticket which was created at night time (18:00~Tomorrow 08:00) during the year.....

 

 

Thanks!

Alan Stephenson
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.
March 6, 2024

True, you are correct. I checked some more and there isn’t one JQL to do what you want. You can possibly do something like what was outlined here;

https://community.atlassian.com/t5/Jira-Software-questions/JQL-for-time-range/qaq-p/1639572

the last line shows how you can do a single day to a partial following day.

I haven’t tested since I’m not in front of a Jira system but it looks like it might work. To do every single day would be hard to do because there is no time range that will do what you are trying. But I will try and report back to you.

Suggest an answer

Log in or Sign up to answer