JQL: How to find issues created in non-working hours?

Hi, any way to find issues that are created this month in non-working hours?

For example, find all issues creted after 19:00, and all issues created in Saturday and Sunday.

And all this in jql filter?

Or with mysql query?

7 answers

SELECT * FROM jiradb.jiraissue

where HOUR(CREATED) > '19:00'

This is in mysql for the hours, but waht about the weekends?

Did you want JQL or SQL? They are not the same.

Hi Norman,

I know they are not the same.

I preffer JQL.

You will need to generate a script that creates the JQL strings and either cut and paste them or create filters.

The following JQL deals with the weekend (ie anything created after 5 pm friday through sunday)

project = JIRA and created >= "2014/05/30 17:00" AND created < "2014/06/02"

Hi Norman,

and thank you for the reply.

I need more global solution, for example to be able to specify only the month, and to to create report for all issues created during weekends and in after-working hours. I think that I'm able to create sting in JQL for all weekends in a given month, but I just need more general solution.

Hi @Todor Kostadinov, i'm looking for the exactr same thing.. I was wondering if you had any luck



Dear Todor, do you maybe found a way for creating the report with tasks which is created at non-working hours?


Thanks a lot,



well this works.. but it's a slow query..

createdDate >= startOfDay(-8h) AND createdDate <= startOfDay(8h) OR createdDate >= startOfDay(-32h) AND createdDate <= startOfDay(-16h) OR createdDate >= startOfDay(-56h) AND createdDate <= startOfDay(-40h) OR createdDate >= startOfDay(-80h) AND createdDate <= startOfDay(-64h) OR createdDate >= startOfDay(-104h) AND createdDate <= startOfDay(-88h) OR createdDate >= startOfDay(-128h) AND createdDate <= startOfDay(-112h) OR createdDate >= startOfDay(-152h) AND createdDate <= startOfDay(-136h) order by createdDate DESC

seems to be the only way..


Dear Fernando, do you maybe found some other way for creating the report with tasks which is created at non-working hours?





Hi Fernando,

as far as I can see the startofDay() function works just for the current day (the same for endofDay() ). Am I wrong?

I'd like to find a solution in order to consider a different SLA if the ticket is created on work hours or not-working hours. 


Thanks in advance,


Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

3,149 views 13 19
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot