Need help with transform map script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-17-2024 06:58 AM - edited 10-17-2024 06:59 AM
Hi Team,
I am doing transformation of data for one of our monitoring tools which is creating incidents in servicenow.
I need to use data stored in staging table to calculate Configuration item and assignment group of Incident.
We have field called "Tags" in staging table which has below data:
Hostname:NAP01-OND02,Vitality:V0,Support Team:Real Time Applications,Application Name:EDS
So Configuration item on Incident should be NAP01-OND02. If this does not exist in CMDB then it should be "CI NOT Present".
Assignment group = Real Time Applications. If assignment group is not found in group table, then populate with CI.support group.
How shall i parse this value and write glide query to populate CI and AG on incident record by creating respective field maps.
Appreciate your support.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2024 01:17 PM
Hello Runjay
The script is not working as expected. Its not setting the CI not found when match is not found in CMDB..there is some issue.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2024 09:41 PM
Hi @dvelloriy ,
I hope you have one ci record with name "CI Not Found" if not then you have to create that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-22-2024 09:21 AM
"CI Not Found" is present. I think the issue is in the logic somewhere.
I guess since config item and assignment group are reference fields, we might need to apply a different logic to set the extracted values of ci and suppG.
Here is the script i am using which is not working. Do you see any issues here?