- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-15-2022 09:08 AM
Hi,
I need to update the RITM fields for which I'm using a BR with cart api, but RITM fields are not getting updated.
Here is my BR condition:
here is my script:
I need this to parent field to be updated on my RITM and request table also how to achieve this?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-15-2022 10:15 PM
Hi,
BR is on sn_customerservice_case table
So you want this case record to be populated inside the RITM's parent field and REQ parent field?
If yes then this can be done
after line 13 query RITM and REQ and update; like this
(function executeRule(current, previous /*null when async*/) {
// Add your code here
var ritm = new GlideRecord('sc_req_item');
ritm.get('request', rc.sys_id);
ritm.parent = current.getUniqueValue();
ritm.update();
var req = ritm.request.getRefRecord();
req.parent = current.getUniqueValue();
req.update();
})(current, previous);
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-15-2022 09:21 AM
You are writing an Insert business rule and condition as Product changes.
How will the product value change when its insert.
May be that's why its not running.
Regards,
Sumanth
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-15-2022 09:26 AM
Hi,
I even tried by removing that condition still it is not getting updated
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-15-2022 09:27 AM
Is this business rule running on the RITM that you're trying to update? Or are you trying to submit a new RITM and then update things? If the latter, what table is the BR running on?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-15-2022 09:51 AM