It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Delete / clear individual rows of change history from JIRA issues

Hi,

Following on from https://answers.atlassian.com/questions/304915.

I would like to know if it's possible to clear individual rows from JIRA's issue change history.

Unfortunately the easiest solution  - updating the issue, cloning it then deleting the original - is the least desired end user option, closely followed by - stopping jira, removing bits from changegroup / changeitem, then restarting - as the IT support team are not supposed to see the data in question and I am a front end administrator only.

I've used the code supplied in the other question to run in Scriptrunner's script console, and I can inspect the element of the row of my issue in question to get the change ID e.g.

<div class="action-details" id="changehistorydetails_12345">

Is there something I can replace ".removeAllChangeItems" with in the below script to pick up the change ID and remove it's details only?

import com.atlassian.jira.issue.Issue;
import com.atlassian.jira.component.ComponentAccessor
def issueManager = ComponentAccessor.getIssueManager()
Issue issue = issueManager.getIssueObject("ABC-1234")
def changeHistoryManager = ComponentAccessor.getChangeHistoryManager()
changeHistoryManager.removeAllChangeItems(issue)
return issue.toString ()

I am using JIRA 7.1.8 if that's any help.

3 answers

1 vote
Thales Santos Mar 12, 2019 • edited

Long shot here after more than 2 years, have you found a way to do this? I am looking for the same thing :)

I'm sorry to say, no I never did! :(

0 votes
Royce Wong Feb 07, 2017

Same here, need to delete individual history entry of a ticket.

0 votes
Diego Godoy Poce May 03, 2019

Same here...

Nici Emmel May 10, 2019

Hello Diego,

there is a plugin on the Atlassian Marketplace which could help you. It is called "Issue History Item Remover".

Diego Godoy Poce May 10, 2019

Hi Nici,

Thanks for your answer, but I need to remove history items as a part of code.

Thank you anyway :)

Suggest an answer

Log in or Sign up to answer
This widget could not be displayed.
This widget could not be displayed.
Community showcase
Posted in Off-topic

Disney Live Action Reboots: Are you for or against?

Happy Friday Everyone! Today marks the international release of Disney's live action version of the animated classic Aladdin. I know that this movie was met with some controversy of over cast...

185 views 21 10
Join discussion

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you