Creation of catalog to delete relationship records from cmdb_rel_ci table in servicenow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-27-2024 11:44 PM
I want to create a catalog to delete the relationships from cmdb_rel_ci table with the approval of CI Owner
Want to have some inputs in catalog design on what all catalog variables should be added to select the relationship records with the help of parent, child and type fields to delete multiple CIs in one go from cmdb_rel_ci table.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2024 01:58 AM
Since the table only has 3 fields that matter, it should be those three plus the reason for relationship deletion.
If you hang a flow behind it to automate the deletion after approval, you're done.
You do need to see how well your CMDB is configured. It may be too much to ask for the relationship, because not everyone understands it. If it's for use cases like applications no longer running on a server, the relationship type doesn't matter, the requestor can just say: I want to delete the relationship between the application and the server.
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
07-28-2024 02:01 AM
Hi @PS28
catalog item to delete relationship records from the cmdb_rel_ci table involves designing the catalog item to capture the necessary information and implementing the logic to perform the deletion with CI Owner approval.
- Create a new catalog item under Service Catalog > Catalog Definitions > Maintain Items with necessary details for deleting CI relationships.
- Add variables for selecting the parent and child CIs, relationship type, and CI Owner approval requirement.
- Develop a script include, to define the logic for deleting relationship records from the cmdb_rel_ci table.
- Use Flow Designer or Workflow Editor to configure an approval process requiring CI Owner consent before deletions proceed.
- Implement a script in the catalog item that calls the script include to perform deletions after approval.
…………………………………………………………………………………………………….
HAPPY LEARNING
Please Mark it helpful 👍 and Accept Solution ✔️ !! If this helps you!!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2024 05:25 AM
Thx for your response, possible to explain more on that will be helpful:
- Add variables for selecting the parent and child CIs, relationship type, and CI Owner approval requirement.
- Develop a script include, to define the logic for deleting relationship records from the cmdb_rel_ci table.
Thx