Not able to delete record ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-21-2017 09:18 AM
We have duplicate test record in model names and we need to delete on that, but not able to doing this
Below error we get it
Delete of Test record not allowed because of a reference in record 5czczb within the Base Configuration Item file
Delete of Test record not allowed because of a reference in record 4888BY within the Base Configuration Item file
How to delete this without lose any other file
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-21-2017 10:20 AM
Hi,
As mentioned by Stacey, This is because of "Reference Cascade Rule" defined as "Restrict" in the dictionary of the reference field, which does not allow you to delete Records if it has some references to the Record.
To avoid this Navigate to the Dictionary of the field and select Reference Cascade Rule as "None". as shown below in the screen shot for example:
You can also the refer the below link for more details in section 7:
Reference Fields - ServiceNow Wiki
Hope this helps.Mark the answer as correct/helpful based on impact.
Regards,
Shloke
Regards,
Shloke
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-21-2017 10:31 AM
Hi Shloke,
I think it wont be a good option to change the cascade deletion for just deleting 2 records. It serves a purpose to maintain CI relationships and we should consider the option only if the entire table should be cleaned up.
Thanks
Please Hit like, Helpful or Correct depending on the impact of the response
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-21-2017 10:38 AM
Hi,
Thanks for your response. By default OOB Reference Cascade is set to Clear or None only, so thought of reverting to what OOB changes are.Can you please help me understand what are the disadvantages if we update the existing Reference Cascade value??
Regards,
Shloke
Regards,
Shloke
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-21-2017 10:49 AM
The restrict is set on purpose to maintain references on model name and prevent its deletion on whichever assets they are referred. For eg: You are deleting a Dell model laptop which is referred in 100's of user assets. If this is not restricted, any accidental deletion of model record would remove it from all related user assets and it can create issues in your asset management or service request modules with data.
If you need to cleanup entire table data, then revert it back and perform delete All Or else just remove the references from the 2 asset records and then manually delete the single model. This ensures the process is maintained on asset data management.
Thanks
Please Hit like, Helpful or Correct depending on the impact of the response
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-21-2017 10:26 AM
Hi,
Please mark the answer as correct if your query is Resolved so that the thread can be closed.
Regards,
Shloke
Regards,
Shloke