Field mappings file specify how fields are mapped and how values are mapped.
Field Mapping
The field mapping files specify how fields in ClearQuest are mapped to Team Foundation fields. Most fields in ClearQuest, except for system and common fields, are mapped one-to-one to Team Foundation. You should keep these field mapping files in synchronization with any changes you make to the fields in the work item type definition files. For example, if you rename a field in the work item type definition file, you should change the mapping file to specify the same mapping. Similarly, if you delete some fields from the work item type definition file, you should delete those fields from the corresponding field mapping file.
Value Mapping
The field mapping files also specify how the field data is to be transformed during migration. By default, no value mappings are generated. You can specify the value mappings if you want to transform data during migration. You specify these transformations using value mappings to say that a value such as "Pri1" should be mapped to "1."
The field map file is an XML file. The following example shows how to map fields and values:
<?xml version="1.0"?>
<FieldMaps xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<!-- Title is a core field in Team Foundation Work Item Tracking and we recommend that you use this field because it best suits the purpose-->
<FieldMap from="Headline" to="Title" />
<FieldMap from="Submitter" to="Submitter">
<ValueMaps refer="UserMap" />
</FieldMap>
<!-- Created Date is a core field in Team Foundation Work Item Tracking and we recommend that you use this field because it best suits the purpose-->
<FieldMap from="Submit_Date" to="Created Date" />
<!-- Assigned To is a core field in Team Foundation Work Item Tracking and we recommend that you use this field because it best suits the purpose-->
<FieldMap from="Owner" to="Assigned To">
<ValueMaps refer="UserMap" />
</FieldMap>
</FieldMaps>
For more information about field maps, see Field Map File Schema.
Mapping to Area Path and Iteration Path Fields
Team Foundation work item tracking organizes the work items into a hierarchy of structural areas and iterations. For more information, see How to: Modify the Team Project Areas, and How to: Modify the Team Project Iterations.
Paths are used to help group work items structurally to represent the various components, projects, or applications your team works on. Iterations are used to help group work items according to major events such as milestones, and project phases. The Area Path and Iteration Path system fields define this information in Team Foundation. Because ClearQuest has no such concept the converter provides a default value for these fields; the default is that all work items go into the root of the Area Path Iteration Path.
Although ClearQuest does not provide Area Path and Iteration Path, you may be using the concepts in some other way. For example you may have a field in your work item types that denotes the particular project a work item belongs to. This roughly corresponds to the Area Path concept. Similarly you may have another field named ‘Fix By’ that denotes the milestone by which you want a particular work item to be fixed. Consider mapping these fields to Area Path and Iteration Path so that the work items appear in these different nodes instead of all in one root node. The mappings are specified in the work item type field mapping files as explained earlier.
The following XML example shows how to map a ClearQuest field named Tree Path with possible values of Area1 and Area2.
<FieldMap from="Tree Path" to="Area Path" exclude="false">
<ValueMaps>
<ValueMap from="Area1" to="Area1" />
<ValueMap from="Area2" to="Area2" />
</ValueMaps>
</FieldMap>
The following XML example shows how to map a ClearQuest field named Fix By with possible values of Alpha and Beta.
<FieldMap from="Fix By" to="Iteration Path" exclude="false">
<ValueMaps>
<ValueMap from= "Alpha" to="Alpha"/>
<ValueMap from= "Beta" to="Beta"/>
</ValueMaps>
</FieldMap>