Skip to content

Conversation

@mitalizope
Copy link
Contributor

Client Script - Maps Incident Fields to Child Problem
Description:
This client script automatically maps key field values from a parent Incident record to a Problem record when the user creates a new Problem and selects an Incident record in the Parent reference field.

Client Script:
Name: IncidentToProblemMapping
Table: Problem [problem]
Type: onChange
Field name: Parent

Script Include:
Name: IncidentDetails
Glide AJAX enabled: checked

Implementation:
Place this script on the Problem table with the condition that it triggers on change of the Parent field. When the selected parent record is from the Incident table, it fetches field values from the Incident using GlideAjax and sets them on the Problem form.
Fields Mapped:
• Configuration Item
• Priority
• Assignment Group
• Short Description
• Description

This file includes a client script that maps the values from parent incident record fields to the problem record fields.
This file contains a script include to get the values of incident record fields.
@WillemZeiler WillemZeiler self-assigned this Oct 6, 2025
@WillemZeiler
Copy link
Contributor

Thank you for your submission. I will mark it to get you points for Hacktoberfest. However, please note that OOTB ServiceNow allows for creating a problem from an incident. We advice to use that instead of custom scripts. Example for workspace: https://www.servicenow.com/docs/bundle/washingtondc-it-service-management/page/product/itsm-workspace/task/create-problem-from-incident.html.

The PR will be closed without merging. But your contribution counts towards the hacktoberfest.

@WillemZeiler WillemZeiler added the hacktoberfest-accepted The PR is accepted for Hacktoberfest, regardless of being merged or not label Oct 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

hacktoberfest-accepted The PR is accepted for Hacktoberfest, regardless of being merged or not

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants