Importing work items from a CSV file

You can import work items from a Comma-separated Values (CSV) file into a project area. You can use the Import Work Items Wizard to create work items or update existing work items.
Before you begin
About this task
You can use the Export Work Items Wizard to export data from work items to a CSV file. In the Export Work Items Wizard, you select which work item attributes to include as columns in the CSV file. The Import Work Items Wizard maps columns in the CSV file to work item attributes if the first row contains attribute names, as is the case for work items exported via the Export Work Items Wizard. If you did not use the Export Work Items Wizard to create the CSV file, make sure that the first row contains the attribute names; otherwise, the Import Work Items Wizard does not map columns to attributes.

The Import Work Items Wizard uses an XML mapping file to map attributes from the CSV file to the work items that it creates or updates. The wizard provides a default mapping file, which you can modify to customize the mapping. You can also generate a mapping file from the CSV file that you provide.

  1. Click File > Import. In the Import window, click Team > Work Items from CSV. Click Next.
  2. Click Browse and navigate to the CSV file that you want to import. Select whether the values in the CSV file are separated by tabs, commas, or something else. If you use a separator other than tabs or commas, click Other and enter the separator in the adjacent field.
  3. Select the project area where you want to create or update the work items based on the contents of the CSV file.
  4. Select whether you want to create new work items or update existing work items. You can also select to create work items when there is no match.

    To enable updating of existing work items, be sure that the CSV file contains a column for the work item ID (usually Id). The Import Work Items Wizard uses the IDs to find matching work items.

  5. To save the default mapping file, click Save Default As. The default mapping file contains entries for all attributes in the project area that you select. To generate a mapping file from the CSV file, click Compute From Data; the generated mapping file contains entries for all of the attributes in the CSV file. Edit the mapping file to customize attribute mapping. To have the wizard use the customized mapping file, click Use custom data mapping, then click Browse to navigate to the file.
  6. Click Finish to import the work items.

Feedback

Did this help? You can provide feedback at Jazz.net (registration required): Comment in the forums or submit a bug