- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2022 12:12 AM
Dear Group members,
we have requirement as below,
For cmdb_ci_win_server table,we need to map location field based on u_server_room,can any one please suggest sample code for setting the location field value based on u_server_room value.
Best Regards,
Naga.
Solved! Go to Solution.
- Labels:
-
Team Development
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2022 02:54 AM
If you want to achieve this whenever the server record is created/updated,
then by this logic location will be same as server room when updated/inserted:-
You need to create a BR on windows table
When to run
actions
Result
Please mark as correct if its helpful to you
Anshu
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2022 03:40 AM
Hi Anshu,
Already some data available with wrong mapping like location field updated based on manager location, so in this case i want to update that data as well,which method is suitable (Background scripts or fix script)
Regards,
Naga
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2022 03:59 AM
background script.
It has a rollback feature if something goes wrong.
Anshu
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2022 04:06 AM
if we write fix script, we can captured and move to other instance but in background script is it possible and fix script also has that rollback feature.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2022 04:38 AM
If you have bulk update you can go for fix script
yes it has rollback option i just found
https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0761248
Anshu