How to get Sprint ID for CSV import

We are attempting to migrate from Team Foundation Server to JIRA. I am looking into importing all of our stories into JIRA and it's going pretty well except that I'm having trouble getting them into the appropriate sprints. My plan was to create the right number of sprints in JIRA by hand then import all the stories from a CSV file into each sprint as appropriate.  However, I keep getting this error:

 

Cannot add value [ [Sprint 18] ] to CustomField Sprint in Issue with summary 'Update multiselect control to allow adding values'. Exception Message: Sprint id must be a number: Sprint 18

 

The CSV file sprints values are things like "Sprint 18". Apparently the importer wants to map that to the internal JIRA sprint ID but I'm having trouble finding out what that is. How does one determine that?

Here is some sample data from the CSV file:

ID,ParentID,Work Item Type,Title,Assigned To,State,Iteration Path,Effort,Description
1716,,Story,Title 1,,Done,Sprint 18,8,Some text
1722,1716,Sub-task,Title 2,John Smith,Done,Sprint 18,,
1884,1716,Sub-task,Title 3,Fred Jones,Done,Sprint 18,,
1737,,Story,Title 4,,New,Sprint 19,5,More text

3 answers

JIRA maintains an equivalent numeric value for each Sprint. The numeric value is what you need to have in the CSV file,

To find the numeric equivalent of a sprint, do the following : Go to Issue navigator, and specify the following query: sprint = Sprint 18.

When you finish typing Sprint 18, you will see the corresponding numeric value displayed in the query

Not terribly useful when trying to export/import thousands of issues and hundreds of different sprints.

Thanks for the input. Unfortunately, that doesn't work that well when you have multiple projects that have sprints with the same name. So if I have two projects each with a sprint called "Sprint 18", I see both sprints in the list and no way to know which one is for which project (aside from maybe the date/time that gets displayed in that list as well). Unless you know of a way to get it to only show one project's sprint in the list.

If we're going to get hacky about it, another way that works is to open Chrome developer (or whatever browser debugger you use) and look at the network activity tab when you do things related to a specific sprint. That usually displays the sprint id somewhere in the query string. For example if you go to Reports and run the Sprint Report with the appropriate sprint selected, you will see something like this in the network tab:

sprintreport?rapidViewId=7&sprintId=22&_=1436199334819

which only shows you one sprint. Of course if you're not a developer you probably don't want go this route, but those of us doing CSV imports are more likely to be devs.

 

 

I created a sample issue and added it to the appropriate sprint.  The issue history shows the new sprint value with both the sprint name and sprint ID.  This worked well since I created all sprints back to back and could simply increment the mapping value in Excel.

You can also get a list of sprints and their IDs using SELECT * FROM AO_60DB71_SPRINT.

Since sprints can be shared across projects, you'll need to ensure it has a unique name to ensure you are mapping to the correct sprint.

I have 3 sprints, but only two are coming up in the query results.   Does anyone know why the one is missing?  

 

Thanks!

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

3,039 views 13 18
Join discussion

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot