I've a dashboard that includes a filter that uses a time period to produce results. The filter aims to list issues that have moved to a Done status in the last calendar month. It uses a statusCategoryChangedDate range, for example:
statusCategoryChangedDate > "2023/11/01" AND statusCategoryChangedDate < "2023/11/30"
The issue is that I have to amend the date range each month. Is there a way to dynamically enter the date range, so I don't have to manually change the dates all the time? For example, LastMonth.
Community moderators have prevented the ability to post new answers.
Your JQL could use the startOfMonth() and endOfMonth() functions, with the modifiers to subtract one month:
project = myProjectName
AND statusCategory = Done
AND statusCategoryChangedDate >= startOfMonth(-1)
AND statusCategoryChangedDate <= endOfMonth(-1)
Please look here to learn more about those functions:
https://support.atlassian.com/jira-software-cloud/docs/jql-functions/#startOfMonth--
Please note: This will find the issues which are currently Done and moved to that condition last month. It will not find issues which moved to Done and which are no longer Done.
To find those, please try using the CHANGED operator with the DURING modifier:
https://support.atlassian.com/jira-software-cloud/docs/jql-operators/#CHANGED
Kind regards,
Bill
Many thanks @Bill Sheboy That is exactly what I was after.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I know the above works, but I wanted to show how I did the same thing with less effort:
AND resolved <= endOfMonth(-1) AND createdDate >= startOfMonth(-1)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Paul Adams, this topic has been locked because the thread has become a bit dated. If you’d like to keep the conversation going or have additional questions, we encourage you to start a new topic. You can read more about necro posting (“raising threads from the dead”) in our Community Guidelines.
Thanks!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
it would be great if there were also "startOfLastMonth()" and EndOfLastMonth()" options too
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.