Jira Cloud: With Scriptrunner, how to filter based on creation and resolution difference?

Tiago Cardoso September 12, 2022

This question is based on the Server version of this question.

Sreenivasaraju P suggests to use ScriptRunner dateCompare function.

issueFunction in dateCompare("", "created +2w > resolutionDate ")

While using it in my Jira instance, however, I got the "Field: resolutionDate is not valid".

Am I doing something wrong? Does this depend on a specific Scriptrunner version?

The feature is supposed to work in both Cloud and Server version.

scriptRunnerError.png

1 answer

1 accepted

0 votes
Answer accepted
Tiago Cardoso September 17, 2022

I found a solution and I have an assumption for the problem in my case.

The query worked when adding a subquery (in this case, making explicit the project I was looking at).

scritRunnerWorking.png

I'd assume that at least one project in my domain does not have this field and thus the error.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events