Copying Incident Fields When Creating Change Request
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
When creating a Change Request from an Incident, it is often useful to automatically copy relevant field values from the Incident to the Change.
ServiceNow already copies some OOB task fields, but organizations usually need additional fields or custom logic.
Instead of manually populating fields every time, we customize the Create Change page in UI Builder.
Step 1: Duplicate the OOB Create Change Request Page
Navigate to UI Builder, search for "Service operations workspace" and locate the page.
create-change-request-page
Click on it to open this page in Editor. On the top middle you can find "Settings". Click on it.
Give a lower order value than the OOB page to make sure it loads first and then the OOB page.
Field Copy Scenarios
There are two scenarios when copying fields from Incident to Change Request.
- Copying task table fields
- Copying custom fields
Copying Task Fields
ServiceNow already copies certain task fields when creating a Change.
Open the new page in Editor and navigate to:
Client State Parameters → taskFields
Verify the fields in the Initial Value property.
Example:
short_description,description,cmdb_ci,priority,assignment_groupThese fields are automatically copied from Incident → Change Request.
To copy additional task fields, simply add them to this list.
Example:
short_description,description,cmdb_ci,priority,assignment_group,impact,urgencyCopying Custom Fields
There are two possibilities when dealing with custom fields.
Case 1: Custom Field Exists on Task Table
If the custom field:
- Belongs to the task table
- Exists on both Incident and Change Request
Then simply add it to taskFields.
Example:
short_description,description,u_business_serviceThe field will automatically copy.
Case 2: Custom Fields Are Different
If fields are not shared between tables, we must modify the client script.
Navigate to:
Client Scripts → Additional Query data from Task
Client Script Logic
The script:
- Fetches the source record (Incident)
- Builds an encoded query
- Maps values into the Change form
Custom Mapping Example
Sometimes fields must be mapped differently.
Example: u_incident_field → u_change_field
Example logic:
if (record.u_incident_field && record.u_incident_field.value) {
query += '^u_change_field=' + record.u_incident_field.value;
}Final Result
When clicking Create Change from Incident:
- Task fields are copied automatically
- Custom fields can be mapped
- Additional logic can be applied
This allows:
- Faster Change creation
- Consistent data transfer
- Less manual work for agents
For more blogs visit my personal blog site:
