- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-11-2025 04:14 AM
Hi all,
I am working a on a requirement whereby I have to add a related list to our Vendor form, showing what Risks have been raised again Vendor CI's. The Relationship is as follows and currently brings back all Risks:
Applies to table: core_company
Queries from table: u_risk_register
Our CI's are held on a table named - cmdb_ci_business_app. I am having a challenge in getting the correct script in order to do this, could someone assist on this please?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-12-2025 04:10 AM
can you try this
(function refineQuery(current, parent) {
current.addQuery('u_business_application.vendor', parent.sys_id);
})(current, parent);
If my response helped please mark it correct and close the thread so that it benefits future readers.
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-11-2025 06:27 AM
u_risk_register is a custom table, so you will have to tell us how these connect. Is the table something containing the CI and the Vendor (I assume not, since that would be an easy list).
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-12-2025 02:31 AM
Hi Mark,
The Vendor is on table core_company, whilst the CI is on cmdb_ci_business_app table (this is on the Risk form as a reference field)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-11-2025 06:40 AM
Please share some details on that custom table, what fields are present on that table?
what script did you try so far?
If my response helped please mark it correct and close the thread so that it benefits future readers.
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-12-2025 02:28 AM
Hi Ankur,
I have tried both of these so far: