Field Clear Map

Removes data from a specified field by setting its value to null during work item migration.

Last updated: June 25, 2025 | Edit this page | Discuss this page

Clears a target field by setting its value to null, useful for removing data from specific fields during migration.

The FieldClearMap is used to explicitly clear a field value on migrated work items by setting the target field to null. This is especially useful for sanitising or removing unwanted metadata, calculated fields, or legacy data that should not be carried into the target system.

top

Purpose and Use Cases

This map is typically used when:

  • You want to remove confidential or obsolete field values from the target.
  • You’re migrating to a system where a field is no longer in use or read-only.
  • A field value causes validation errors in the target and should be reset.
top

Options

Parameter Type Description Default Value
ApplyTo List A list of Work Item Types that this Field Map will apply to. If the list is empty it will apply to all Work Item Types. You can use “*” to apply to all Work Item Types. missing XML code comments
targetField String Gets or sets the name of the target field to be cleared/set to null during work item migration. missing XML code comments
top

Behaviour

  • Clears the value of the specified targetField by setting it to null.
  • Executed before saving the work item to the target.
  • Only affects the latest revision unless the processor is configured to rewrite history.
  • Will silently overwrite any existing value in that field on the target.
top

Practices

  • Ensure that the targetField is writable in the target project.
  • Use this map only when you intentionally want to remove data; it will override any mapped or default value.
  • Combine with ApplyTo to limit field clearing to specific types where the field is present.
  • Be cautious when clearing system fields; not all fields accept null values.
top

Limitations

  • Does not validate whether the field actually exists on the target.
  • If targetField is a required field in the target process, this may cause a validation error.
  • Does not support conditional clearing; the field is always cleared if this map applies.
top

Samples

top

Sample

Sample

{
  "MigrationTools": {
    "Version": "16.0",
    "CommonTools": {
      "FieldMappingTool": {
        "FieldMaps": [
          {
            "FieldMapType": "FieldClearMap",
            "ApplyTo": [
              "SomeWorkItemType"
            ],
            "targetField": "Custom.FieldC"
          }
        ]
      }
    }
  }
}
top

Defaults

Defaults

{
  "MigrationTools": {
    "Version": "16.0",
    "CommonTools": {
      "FieldMappingTool": {
        "FieldMaps": [
          {
            "FieldMapType": "FieldClearMap",
            "ApplyTo": [
              "*"
            ]
          }
        ]
      }
    }
  }
}
top

Classic

Classic

{
  "$type": "FieldClearMapOptions",
  "targetField": "Custom.FieldC",
  "ApplyTo": [
    "*",
    "SomeWorkItemType"
  ]
}
top

Metadata

Project Information
Azure DevOps Marketplace
YouTube Channel
Maintainer

Created and maintained by Martin Hinshelwood of nkdagility.com

Documentation Versions
Production Azure DevOps Migration Tools Release Version
Preview Azure DevOps Migration Tools Preview Version
Getting Support
Community Support
Questions & Discussions

The first place to look for usage, configuration, and general help.

Commercial Support

We provide training, ad-hoc support, and full service migrations through our professional services.

Azure DevOps Migration Services
Documentation