
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-14-2018 06:47 AM
So I have been looking for a way to filter a field that has the type of "Table Name" to only show tables that are an instance of CMDB and I'm not finding a way to do it.
I tried "nameINSTANCEOFcmdb" but that did not work.
Anyone have any thoughts on this?
Solved! Go to Solution.
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-14-2018 06:58 AM
The system does not show the fields on the form. I'm/was hoping that I could find a way to do it.
Right now I'm using a reference field to sys_db_object then I used the Ref Qual of "nameINSTANCEOFcmdb". Just not a fan of how it came out.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-15-2024 02:47 AM
@Jon G1 Thanks a lot for sharing this Jon.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-04-2024 03:46 AM
Super old thread but just want to add that - if you want to also include "None" - you want to include the "Include None" attribute to be true. As this solution will default to the first table in the array.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-13-2020 06:35 AM
Once again, I'm super late to the party, but in case anyone else needs this...
On a table name field you can use the base_table attribute to determine the base table to start with. In this case, base_table=cmdb_ci should show the cmdb_ci table and all tables extended from it, but not any other tables.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-22-2021 02:00 PM
Hi
Am I doing something wrong or it's generally not working in this case?
thanks,
Nari.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-23-2021 05:36 AM
If you are showing both on a form, the table name field should be limited by base_table, and document id limited by table name. But, if you search on the document id field with the magnifying glass, however, a GlideModal form of the document_selector ui page is presented. That ui page makes no mention of the base_table attribute, and, as you have found, you can select any table.
I don't see an easy way to update that ui page, and even if I did, I would recommend against it, as that is an out of the box ui page that may be updated in a future version of ServiceNow.
There may be an attribute you can put on the document id field to limit it, but I didn't see one either by looking on the dictionary record for a document id field, or by looking through the document_selector ui page.
If you really need this functionality, I recommend reaching out to ServiceNow's HI team to see what they have to say, as I don't see a way around the current implementation without risking issues during future upgrades.
Good luck!