Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

how to delete particular jira project issue using sql or rest api?

soumyajit February 28, 2019

Actually I'm trying to delete particular project issue using through the bulk delete option, but it's not working. I have not received any error just bulk operation hang up.Could you please suggest me there are any alternative way to delete issues from particular project.

Means using sql query or rest services.

I am using jira 7.6.6 currently

2 answers

1 vote
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 2, 2019

I won't repeat what Joe said, but I do agree - you need to be absolutely 100% certain that you will never need to see those issues ever again, so check with your users, your auditors and compliance people before even thinking of  deleting them.

On to the practical side of this - do NOT try to do it with SQL, that way lies madness.  While the core of an issue is in the jiraissue table, most of the data attached to it is not.  You need to be sure you have deleted the data from every place for any single issue and as that could be smeared over 80% of the tables in Jira (let alone plugins), it's a total nightmare.

The bulk delete you have triggered is by far the best way to do it.  It does time out on large operations on lower-powered servers, but it does continue to work.

For the REST option, see https://docs.atlassian.com/software/jira/docs/api/REST/7.12.0/

soumyajit March 5, 2019

For rest api option you can delete single issue, there are noway to delete multiple issues.

0 votes
Joe Pitt
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
February 28, 2019

Do not delete issues. When you delete it is GONE. Hardly a week goes by without someone wanting to restore an issue. Deleting issues will come back and bite you when it is the most inconvenient. I suggest closing with a resolution value of Deleted anything you want to delete. I implement a special transition only the project lead can execute and it requires filling in a reason field from a select list (such as entered in error, OBE, Duplicate, Other) and explanation text.

Deleting issues destroys historical data. Missing issue numbers will eventually cause a question about what it was and why was it deleted even if it was done properly. Missing data always brings in the question of people hiding something that may have looked bad.

 

 

The only viable way to restore an issue is to create a new instance of JIRA and restore a backup that has the issues. Then export them to a csv file and import them to your production instance. You will lose the history.

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, atlassian government cloud, fedramp, webinar, register for webinar, atlassian cloud webinar, fedramp moderate offering, work faster with cloud

Unlocking the future with Atlassian Government Cloud ☁️

Atlassian Government Cloud has achieved FedRAMP Authorization at the Moderate level! Join our webinar to learn how you can accelerate mission success and move work forward faster in cloud, all while ensuring your critical data is secure.

Register Now
AUG Leaders

Atlassian Community Events