When a table extending sys_metadata is deleted from the UI, if there were records in that table, then the corresponding sys_metadata records are not removed.


Steps to Reproduce


  1. Create a new table that extends sys_metadata.

  2. Navigate to that table and create a new record in it.

  3. Note the sys_id of the the record you just created.

  4. Delete the table (without deleting the record in it).

  5. Navigate to sys_metadata and search by sys_id using the id from step 3.

    Note that the record has not been removed.


This problem was fixed since Istanbul Patch 5. If the affected instance can not be upgraded yet, please follow the steps below:

  1. Identify the corrupt rows due to orphan records in sys_metadata by editing the following URL to point to the affected instance and specify the name of the deleted table:


  2. Click the information icon to confirm that the records are not valid.

    A blue info message stating Record not found should display.

  3. Select affected records in the list and delete them. If the delete fails, reach out to ServiceNow support to remove the orphan records from the database.

Exceptions thrown during Source Control operations may leave the repository in a bad state causing issues with next operations. Once above cleanup is complete, apply the workaround from KB0622002 to prevent further thrown exceptions.


Related Problem: PRB684316

Seen In

Geneva Patch 7
Helsinki Patch 0 Hot Fix 1
Helsinki Patch 1
Helsinki Patch 3

Fixed In

Helsinki Patch 10
Istanbul Patch 5

Associated Community Threads

There is no data to report.

Article Information

Last Updated:2019-05-21 11:35:54