Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,467,941
Community Members
 
Community Events
177
Community Groups

How to bulk edit the summary field

I need to add an additional common text ( heading of the parent issue) to all the subtasks. 

I tried doing this with bulk edit, but bulk editing of 'summary' field is not allowed in JIRA. 

I think JIRA should allow the bulk edit option for summary field ( only - 'add to existing text'). 

4 answers

6 votes

Hi @Shiva Dainak 

If you're a Jira Admin, you can do this using CSV Import.

This is how I'd do it:

  1. Go to Filters > Advanced Issue Search
  2. Search for all sub-tasks which need to be modified
  3. Make sure Summary is one of the visible columns, then press Export > Export Excel CSV (current fields)
  4. Modify the Summaries in Excel in bulk
  5. Ensure the Issue Key remains on the CSV file, along with the Summary, then re-save the file.
  6. Next, as a Jira Admin go to Settings > System > External System Import
  7. Select CSV, and follow the steps to upload your file. Ensure when mapping the fields you map "Key" to "Issue Key" so the importer updates the existing issues, rather than creating new ones

For more information on updating issues via CSV import, see this page - specifically the section Updating existing issues

Ste

I love you, @Stephen Wright _Elabor8_. This saved me a lot of time.

hi @Stephen Wright _Elabor8_ 

I have an error when importing the data. I just want to bulk edit labels, so I just map : Summary (as required one), Issue Key and Labels. 

Here is the screenshot of the error. Please advise. Thank you.

Kind Regards,
Moyo

Screen Shot 2022-01-23 at 21.10.49.png

Hi Ismoyo,

Did you rectify this issue?

Ste

Hi Stephen, hope you are doing well!

Thanks for detailed steps to edit Summary - I intend to correct summary of 4 user stories (screenshot attached)..

Followed the steps and tried to upload .csv file with Issue Key and Summary.. Under mapping, Summary is under "Summary" but for "Issue Key" - I couldn't find "Key" field in JIRA , option available is "Issue ID" - please find screenshot attached.

Should I select Issue ID ? Please advise, Thank you!

Hi @Ritu.Nikhildebnath 

Can I confirm which CSV Import tool you are using?

  • Is it via Filters > Advanced Issue Search > Options > Import Issues from CSV?
  • Or, is it Jira Settings > System > External System Import?

You need to use the latter for updates.

Ste

Hi @Stephen Wright _Elabor8_ 

I have the same problem & I'm using the External System Import

Nick

Hi @Nick Berger 

Tested this and it works fine on our system.

What options do you see when trying to select from the list?

Ste

Hi Stephen @Stephen Wright _Elabor8_ 

I tried your method with 2 tickets (thankfully) and the system created two (2) new tickets.

I only wanted to change summary field so in addition to "Key Issue" field I included "Summary" and two lines showing data for those two fields only.

I got two new tickets with a new Key Issue # and Summary that included the old Key Issue # and Summary data I provided.

Was I wrong in thinking that the system would update only the Summary data?  if not, what do I need to do, please?  We don't want new tickets - only the Summary field updated in the existing tickets.

TIA

Hi @Laura Anderson 

Can I confirm which CSV Import tool you are using?

  1. Is it via Filters > Advanced Issue Search > Options > Import Issues from CSV?
  2. Or, is it Jira Settings > System > External System Import?

You need to use (2) for updates.

If you are using (2), assuming this is for one Project, your CSV file will require the Issue Key you're looking to update, and the Summary field, at minimum.

You then need to ensure the Issue Key is aligned to the correct "Issue Key" field when mapping the fields. This mapping needs to be correct for an update to be made, rather than a new issue creation (which is the default otherwise).

Ste

Hi @Stephen Wright _Elabor8_ thanks for replying - sorry for the delay in my response.

I've exported the tickets into a CSV file, changed the Summary field, and are using 'Import Issues from CSV'.

it's the Summary field that I need to change the data in - no other fields.  Wondering why the Issue Key isn't sufficient to link the change.

Hi @Laura Anderson 

Are you accessing the Import Issues from CSV via...

  1. Filters (on the top navigation) bar
  2. Advanced Issue Search (from the drop-down menu)
  3. Pressing the breadcrumbs (3-dots icon) > Import Issues from CSV

...?

If yes, this is the user importer, which can only create new issues, not import updates to them in bulk.

---

To perform updates, you'll need to use the Jira Admin Importer - you'll need to be a Jira Admin, and then:

  1. Select Settings (cog icon in top-right) > System
  2. Choose External System Import from the left-hand menu
  3. Select CSV, and follow the instructions

Ste

Hi @Shiva Dainak and welcome to the community!

You can also use our Jira cloud app Advanced Bulk Edit for Jira to bulk edit the summary.

With our app you can:

  • Add text as a prefix
  • Add text as a suffix
  • Replace terms with other terms (e.g. replace "bunny" with "rabbit)

Don't hesitate to contact our support if you have questions or feedback about Advanced Bulk Edit for Jira.

@Stephen Wright _Elabor8_  Hi Stephen - you there?

If you have a ScriptRunner plugin, then you can create a Listener with it, which will do the job.
I did it this way:

  • created a new custom "text single line" field - Summary_hidden (without adding it to screens), with "Indexing" switched to Off
  • created a Custom Listener for Issue Created & Issue Updated events

The Listeners code do the job - when it is triggered it takes data from hidden field and put it into the system field, then do re-index. The Summary_hidden field is visible on the Bulk Edit page.


import com.atlassian.jira.event.issue.IssueEvent

import com.atlassian.jira.issue.IssueManager
import com.atlassian.jira.issue.MutableIssue
import com.atlassian.jira.event.type.EventDispatchOption

import com.atlassian.jira.issue.Issue
import com.atlassian.jira.component.ComponentAccessor

import com.atlassian.jira.issue.index.IssueIndexingService
import com.atlassian.jira.util.ImportUtils

import com.atlassian.jira.issue.fields.CustomField

Issue issue = event.issue
IssueManager issueManager = ComponentAccessor.getIssueManager()
def currentUser = ComponentAccessor.getJiraAuthenticationContext().getLoggedInUser()
MutableIssue issueMutable = (MutableIssue) event.issue
final String CUSTOM_FIELD_ID_FOR_SUMMARY_HIDDEN = "customfield_11900"
def customFieldManager = ComponentAccessor.getCustomFieldManager()
def cf = customFieldManager.getCustomFieldObject(CUSTOM_FIELD_ID_FOR_SUMMARY_HIDDEN)

String summaryValue = issue.getSummary()
String summaryHiddenValue = issue.getCustomFieldValue(cf)

String eventTypeName

if (event instanceof IssueEvent)
{
Long eventTypeId = event.getEventTypeId();
def eventTypeManager = ComponentAccessor.getEventTypeManager()
eventTypeName = eventTypeManager.getEventType(eventTypeId).getName()
//debug
//log.warn("SummaryChanger: eventTypeName=="+eventTypeName+" JRA_ID=="+event.issue.key)
//debug
}
else
{
return
}

def changeLog = event?.changeLog
def changeItems = changeLog.getRelated("ChildChangeItem")
Boolean IssueSummaryChanged = changeItems?.find{ it.field == "summary"}
Boolean IssueSummaryHiddenChanged = changeItems?.find{ it.field == "Summary_Hidden"}

//debug
//changeItems.each{log.warn("SummaryChanger: Items: "+it)}
//debug

Boolean needIssueReindex = false

if ((eventTypeName == "Issue Updated" && IssueSummaryChanged) || (eventTypeName == "Issue Created")) // filling the hidden field. if you need it.
{
issueMutable.setCustomFieldValue(cf,summaryValue) // копируем новое summary в скрытое поле
issueManager.updateIssue(currentUser, issueMutable, EventDispatchOption.DO_NOT_DISPATCH, false)
//needIssueReindex = true
}
else if (eventTypeName == "Issue Updated" && IssueSummaryHiddenChanged) // summary_hidden updated via bulk update (field is not on any screens, so bulk update is the only possibility to change it)
{
issueMutable.setSummary(summaryHiddenValue)
issueManager.updateIssue(currentUser, issueMutable, EventDispatchOption.DO_NOT_DISPATCH, false)
needIssueReindex = true
}

if (needIssueReindex)
{
def issueIndexingService = ComponentAccessor.getComponent(IssueIndexingService)
Boolean wasIndexing = ImportUtils.isIndexIssues()
ImportUtils.setIndexIssues(true)
//debug
// log.warn("SummaryChanger: Reindex issue ${issue.key} ${issue.id}")
//debug
issueIndexingService.reIndex(issueManager.getIssueObject(issue.id))
ImportUtils.setIndexIssues(wasIndexing)
}

I'm a newbie to the Java/Groovy, so, please do not blame me ;)

Suggest an answer

Log in or Sign up to answer