I'm trying to formulate a query that can search a date range and return only the tickets created on weekends.
Here's a clunky solution that you may find viable. Once initially created, it'll be pretty quick to maintain and run when needed.
Use Excel to create several OR'd conditions covering several weekends.
See my example screenshot.
I placed the first Saturday of 2019 in A1 and the first Monday of 2019 in B1.
C1 contains the formula:
=CONCATENATE("(created >= ",TEXT(A1,"yyyy-mm-dd")," and created < ",TEXT(B1,"yyyy-mm-dd"),") OR ")
A2 contains the formula =A1+7 and B2 contains the formula =B1+7 and C2 contains a copy of C1.
I then highlighted the 3 cells on Row 2 and clicked the square at the bottom right and dragged downward to copy, making several weekends.
Finally, I copied and pasted column C into a JQL field, removing the final "OR"
Hello @Masroor karamat
For a specific week you can exclude/include weekends based on the functions startOWeek/endOfWeek but directly excluding/including weekends for a date range is not supported right now in JQL.
Possible duplicates
https://community.atlassian.com/t5/Jira-Core-questions/JQL-query-for-a-Work-Week/qaq-p/205336
https://community.atlassian.com/t5/Jira-Core-questions/Exclude-weekends-in-JQL-Query/qaq-p/1030290
Open ticket https://jira.atlassian.com/browse/JRASERVER-27539
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.