I am using scriptrunner plugin and querying for out of SLA tickets that have a resolved date that are 60+ from the creation date. The problem i am running into is there are quite a few tickets that have a creation date from 3-4 months back without a resolution date. I also want to include those tickets that have no resolution date but they have to be 60 days or greater than their creation date.
This is what I have so far, I cant seem to get the last piece to include empty resolution greater than 60 days from the creation date. DO i add something like this
created > startOfDay(60d)??? when I add that to the query it breaks.
issueFunction in dateCompare("filter = "ENGR: INCIDENTS" AND project !=OPS AND project !="ERS Problems" AND priority = "High - P1" AND created >="2022-01-01" AND Status not in (Canceled, "Won't do/won't fix") ORDER BY created DESC", "resolutiondate > created +60d")
Hi @Anthony Martinez and welcome to the community,
If you want to use the startOfDay JQL function to query your issues, then you can use like below:
created >= startOfDay(-30)
If you add the above on your overall JQL, I think that you will not have a problem.
In addition you have on your JQL the following:
"resolutiondate > created +60d"
which will return always an error. You can't compare variables and/or add numbers (or days) to other variables. JQL doesn't work like this.
Let me know if the above worked out for you.
Hi @Anthony Martinez ,
welcome to the Atlassian community!
In order to retrieve tickets created more than 60 days ago you can use the following :
created >= -60d
Please try and let us know.
Fabio
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.