Hi Team,
Need to get a function in JIRA for getting the last closed sprint which should be OpenSprint()-1, can you share the details for this.
Don't want to use script runner or any other plugin for this
Hi @Sameer Bansal , unfortunately there while there is a closed sprints function there isn’t a “previousSprint” function. Obviously you can find previous sprint details in Reports. Is there some specific goal you are aiming for?
@Jack Brickey Actually i have created a dashboard wherein we want to compare the current sprint and previous sprint for management reporting. Right now it's a pain to change the previous sprint number everytime and if someone miss to update that then complete report doesn't make any sense
That is what I thought you might be attempting. Actually did you try this…
Sprint in openSprints(-1)
I don’t currently have any open sprints to verify this but a quick test says it might work.
@Jack Brickey - yes, openSprints(-1) doesnt do anything just shows open sprint adding -1 or anything in the brackets doesn't seem to work. maybe its a bug or i don't know
Hi @Sameer Bansal
Yes, and...to what Jack notes: there is nothing built-in to do this yet.
As a work-around, you could use the built-in automation rule features to help in a few ways:
Best regards,Bill
@Bill Sheboy -
1) for REST API an not sure what will be the trigger point for the automation rule
2) for option 2 the requirement is to distinguish the current and previous sprint
For option 1, you could trigger the rule on sprint completed.
Further to @Bill Sheboy suggestions, if you are happy to receive whatever info it is you are after via email (from an automation rule), I've just got this working to report on the mentioned issue types in the JQL for the sprint that triggered the rule to run, by using the {{sprint.id}} smart value in the JQL.
it didnt worked, so i discarded the idea will check in future if reqired
I was able to achieve previous sprint using the following:
fixVersion in unreleasedVersions() and project = [YOUR_PROJECT_NAME] and fixVersion in releaseDate("after now() before 30d")
Hi @Daniel Martin -- Welcome to the Atlassian Community!
I do not see the releaseDate() in out-of-the-box JQL functions. Are you using a marketplace addon to provide that feature?
Kind regards,Bill
It looks like you're new here. Sign in or register to get started.