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



No, sorry.

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 Sign up to answer
Community showcase
Published Wednesday in Jira

Make your Atlassian Cloud products more secure: our NEW admin security guide

Hey admins! I’m Dave, Principal Product Manager here at Atlassian working on our cloud platform and security products. Cloud security is a moving target. As you adopt more products, employees consta...

136 views 0 6
Read article

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