- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-17-2024 12:26 AM
- If not do we need to delete them in individual instances?
- What need to be considered before deleting the table?
- Is parent table fields going to be affected if I deleted child table?
- Except schema map is there any other feature available in ServiceNow to track where and where they are using this table?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-17-2024 01:35 AM - edited 05-17-2024 01:38 AM
Hi,
This is a very Broad Question but here are my 2 cents on the same
- If not do we need to delete them in individual instances? -> It is captured in the update set, but I would say do it manually.
- What need to be considered before deleting the table? --> Deleting all related components before dropping the table.
- Client Scripts
- Ui policies & ui policy actions
- ACLs
- BR
- UI Action
- Left Nav Menus
- Reports
- If this table is parent of any other table
- Flows/Workflows
- Integrations
- If the data in this table falls under Data retention policy of your company then you may need to decide this before dropping the table.
- ETC
- Is parent table fields going to be affected if I deleted child table? -> No
- Except schema map is there any other feature available in ServiceNow to track where and where they are using this table? -> Schema map will show you where the table is referenced and if any table extends this but it wont show the scripts where this table is used and being called from. So it may still lead to some queries failing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-17-2024 12:39 AM
Table deletion will be in an update set. But it is wise to just do it on the instances themselves, to see if any errors or warnings are given that you didn't get on the lower instance.
Deleting a table will delete the table, it's fields and all content in the records. You say it's a child table, so the question really is: why. You can also just make it so people can't create any more records. If you delete it, it will take away all references to it from the parent table, which (depending on the usage) could show weird things, like links to non existing records if you copy data from the child to another table.
Removing the child table means you also need to check on any logic from (easy) and to (harder). If you have a flow or BR updating the child table from the parent, you will need to inactivate it. You could run into weird things, depending on your setup if you don't.
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
05-17-2024 01:18 AM - edited 05-17-2024 01:20 AM
Have a look at this documentation: https://docs.servicenow.com/bundle/washingtondc-platform-administration/page/administer/table-admini...
Use background script or Fix Script to delete a table.
In addition to what Mark said above - use "Code Search" tool (here) to find all the places where your table is used.
Cheers!!
Anu
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-17-2024 01:35 AM - edited 05-17-2024 01:38 AM
Hi,
This is a very Broad Question but here are my 2 cents on the same
- If not do we need to delete them in individual instances? -> It is captured in the update set, but I would say do it manually.
- What need to be considered before deleting the table? --> Deleting all related components before dropping the table.
- Client Scripts
- Ui policies & ui policy actions
- ACLs
- BR
- UI Action
- Left Nav Menus
- Reports
- If this table is parent of any other table
- Flows/Workflows
- Integrations
- If the data in this table falls under Data retention policy of your company then you may need to decide this before dropping the table.
- ETC
- Is parent table fields going to be affected if I deleted child table? -> No
- Except schema map is there any other feature available in ServiceNow to track where and where they are using this table? -> Schema map will show you where the table is referenced and if any table extends this but it wont show the scripts where this table is used and being called from. So it may still lead to some queries failing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-17-2024 04:53 AM
Thanks for your detailed explanation @Anurag Tripathi
I just had a question In PDI I created X, Y tables and created sample records, out of them for X ...I went to dictionary for collection type i kept audit as True and for Y i didn't.
In both the cases I am able to delete them and able to restore through sys_metadata_delete and Deleted records.
In that case what makes difference here?
Note: I have read some articles that we can get back only audited tables but not others.