Matching Exported Issue Data to Update JIRA Projects with JIRA Importers Plugin
It is sometimes necessary to run exports out of multiple bug trackers in order to bulk-update JIRA issues with the JIRA Importers Plugin (JIM). Some examples would be:
- The JIRA Importers Plugin functionality Import from Bugzilla is not compatible with all fields generated by Bugzilla
- Rolling back a JIRA update while retaining changes made post-update
In such cases, existing JIRA issues need to be updated with new data (new fields, updated existing fields, etc.). This article describes processes by which you can make these types of changes.
The JIRA Importers Plugin is used for two purposes - importing new data into JIRA as new issues and updating existing JIRA issues with modified data.
In order to update existing JIRA issues, it is important to note that the file to be imported must contain, at the least, columns containing the following data to match existing issues:
- Issue Key
Furthermore, the import file needs to be arranged such that issue key is the first column in the file.
This data is required, because it is how the Importers Plugin maps CSV data to JIRA issues.
These steps are written using the example of updating issues in an instance of JIRA previously populated with Bugzilla data.
- Generate CSV export(s) from Bugzilla containing:
- Any field(s) you want to update into JIRA
- Generate Excel export(s) from JIRA containing:
- Issue Key
- Custom field associated with bug_id from Bugzilla
By default, JIRA is set to limit Excel exports to 1000 Issues due to high memory usage. This setting can be changed but is ultimately limited by the amount of memory allocated to your Java Virtual Machine.
Appending CSV File
- Open CSV and XLS files
- Sort all data within both files by a common column
- Copy/paste desired columns to create a complete file
- Save as CSV
- Import to JIRA
Prepare CSV File
- Open CSV file
- Select all rows/columns (Ctrl+A/Cmd+A may be useful here)
- Sort by column 'bug_id' descending
- Insert new column A
Prepare XLS File
- Open XLS file
- Delete header/footer rows so file contains only column names and column data
- Select all rows/columns (Ctrl+A/Cmd+A)
- Sort by column with bug_id data (example: 'External Issue ID') descending
- Select Issue Key column
- Copy (Ctrl+C/Cmd+C)
- Select cell A1
- Paste (Ctrl+C/Cmd+C)
- Rename cell A1 to "Issue Key"
- Save CSV file
- Close XLS and CSV files
When finished, the CSV file should look similar to this:
Using the CSV pictured above, it would be possible to update Issues IK-1 through IK-5 with the bug_id and/or qa_contact fields.