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

Import sub-task from CSV file

Yehuda Maor July 15, 2021

Hi There. 

I'm trying to import data of sub-task form CSV. I'm getting good "how to" information form this page: https://support.atlassian.com/jira-cloud-administration/docs/import-data-from-a-csv-file/

However I still have some road blocks:

1. I can't see an option to map 'Issue Key' field. When I'm trying to search for it to map it to my CSV input I don't see matching Jira field

2. The issue type that I'm trying to upload is a subtask but I can't map the 'Issue Type' filed (similar to the above)

Any suggestions?

Thanks, 

4 comments

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 15, 2021

Welcome to the community!

I'm afraid I only have clarification questions:

1.  Are you creating new issues, or trying to update existing ones?

2.  Do you have at least one sub-task issue type in the project you are trying to import into?

Like Andréa Aline de Faria likes this
Yehuda Maor July 19, 2021

Thanks for the feedback even though those are only clarification questions....

1. I'm trying both - updating existing issues (sub-tasks, actually) as well as creating new one 

2. I do have few sub-tasks - those that I'm trying to update

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 19, 2021

Ok, I would separate this into two pieces, the create and the edit, simplifying each part.

When you are creating issues, you do not give it an issue key, Jira creates new issues in sequence in the project they are being added to.  

If you are just doing edits, then you do need the issue key to tell Jira what issues to update - last time I looked, that maps to just "key", not issue key.

Yehuda Maor July 20, 2021

Thanks

What about the other part?

I'm interested in creating (or updating) not just an 'issue' but a sub-task. I couldn't understand how to do the mapping so that the issue type will be sub-task.

Refer to 'Creating sub-tasks' paragraph in this article : https://support.atlassian.com/jira-cloud-administration/docs/import-data-from-a-csv-file/ 

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 20, 2021

The "other part" is the create or edit that you are not currently looking at.

If you are creating an issue, you do not give it an issue key.  

If you are creating sub-tasks, you need to give them a pointer to the parent issue they belong to

When updating an issue, you have to give it the key of the subtask you are trying to update.

Like Arnaud Lepicier likes this
Yehuda Maor July 20, 2021

Okay, I'll handle one objective at a time

Starting with editing existing issues - I Have the issue key as a column in my CSV file but when I'm trying to map it to Jira field I can't find 'key' field

I found 'issue id' (which is also in my CSV file) and tried to use that but it didn't work - the lines from my CSV file have been created as new issues (instead of updating the existing issues that have the same 'issue id')

Please advise  

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 21, 2021

Ok, I was thinking of the server import when I said "key".  

When you are mapping your columns, it does not matter what they are called in your CSV, but for updating issues, map the column with the existing issue keys (ABC-123) to be updated on to the "issue key" that is offered in mapping.

Yehuda Maor July 22, 2021

I understand that it doesn't matter how the column is called in the file.... what I meant is that I couldn't find neither 'issue key' nor 'key' offered in mapping (... to be mapped to my column)

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 22, 2021

It will vanish from the offer if you have mapped it already.  Have you tried starting from scratch with a very simple import file?

Yehuda Maor July 23, 2021

Yes.

My field (in the 'CSV Fields' column in the 'Map Fields' step of the upload procedure) name is 'Issue Key' and as we've established that is not important

I'm typing 'K' in the 'Jira Fields' column and immediately getting 'No Matches' response

Another comment coming up to my mind just now, I'm not sure if it's event relevant but just to cover all bases - the platform I'm working on is 'Jira Service Desk' (as I said - if it's even mater....)

Yehuda Maor July 23, 2021

One more comment - 

The only fields that are offered for mapping are my custom fields that are included in my project, Jira fields: Labels and Summary only and Links and Sub-Tasks fields: issue ID and parent ID only. No other field is being offered at all

Yehuda Maor July 23, 2021

Okay, another piece of information - 

I added 'Issue Type' system field to my screens and now i ca see this field also offered for mapping under Jira Fields along with Summary and Labels. I tried to look for 'Key' in order to do the same but I didn't see it anywhere

Vinod Kotiya February 23, 2023

All are giving wrong answers and Even JIRA documentation is wrong. The parent ID should not be numerical but the existing key. Here is example of how to add sub-task to existing task or story. All are giving wrong answer by importing new task and sub-task. Capture.PNG

David Griffin March 2, 2023

Vinod is correct, plus the Issue ID should just be a consecutive number. That's what worked for me anyway.

Like Vinod Kotiya likes this
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 2, 2023

I'm afraid this is still wrong.

@Vinod Kotiya , I'm sorry, but you are mixing up "Jira issue ID" with "unique identifier in the CSV import"

They can be the same thing if it fits your data - the unique identifier for an issue just needs to be a unique string, and, of course, Jira issue keys match that, they are unique strings within that Jira install.

But you don't need to use the key, and you cannot do it when you are trying to import the issues with sub-tasks.

The data you show in your screenshot could work fine - when imported, it should be able to create 7 sub-tasks on PJP-6002.

But you are assuming PJP-6002 already exists in Jira here.

How does it work when the issue does not already exist?  You need an identifier in the CSV that allows Jira to distinguish the issues.

There are absolutely not "all wrong answers", and the Jira documentation is right.

Vinod Kotiya March 3, 2023

Why i said answer is wrong because as question ask only about importing the sub-task. But all answers are related with importing task alongwith sub-task. For that reason my above answer is100% correct to import sub-task from csv for existing issue ID. 

JIRA documentation is all about importing task alongwith sub-task that use unique identifier. You can check my next reply at bottom for clarification. I am not mixing up anything. Thanks

Vinod Kotiya March 2, 2023

For Fresh Import (Not importing under existing issues): For Epic > Task(Story) > Subtask import using CSV use following format. Ids are serial number used for import and later discarded by system. Capture.PNG

Emanuel Y December 13, 2023

@Vinod Kotiya is a 100% correct. I've done this several times. :-) 

Like Vinod Kotiya likes this
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
December 14, 2023

Yes, it's not what Vinod was saying in previous answers.  

This is exactly what the documentation says to do.

Like Vinod Kotiya likes this
Šimun Bakula April 19, 2023

I am experiencing same problem while trying to add subtask to existing task (that already has subtask in it)
@Vinod Kotiya could you please put a screenshot of "Map fields" so i could do a comparison?
Thank you.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
December 14, 2023

The field mapping is simple - if you take a look at Vinod's corrected answer from March 2nd, he's given the column headings as the names of the fields in Jira you would map. 

Map "Epic name" to "Epic name", "Summary" to "Summary" and so-on.

Except "Issue ID" and "Parent ID".  Do not map them at all.  They are used to show the relationships between the issues and sub-tasks.

Like Vinod Kotiya likes this

Comment

Log in or Sign up to comment
TAGS
AUG Leaders

Atlassian Community Events