Some PDIs are currently unavailable, and PDI actions are paused. View the latest updates here. Read More

does 123TEXTQUERY321 work on reference fields on a table?

spaceman2023
Tera Expert

Hi guys,

 

i ran into 123TEXTQUERY321 and was testing it using table API and i noticed that it sometimes works on dot walked fields and sometimes it doesn't so i was wondering, is this behavior expected? also is this a good way to do text field search via API?

2 REPLIES 2

Tanushree Maiti
Tera Patron

Hi @spaceman2023 

 

When you perform a text search on the Incident table using a value like 123TEXTQUERY321, ServiceNow searches all fields included in the Incident table's text index (Zing search).

This works seamlessly for indexed fields on the Incident table itself.

 

However, if you attempt to search using a dot-walked reference field (e.g, caller_id.department.name), the search will only work if the referenced table and its fields are also included in the text indexing process. Otherwise, the query may return no results or ignore that portion of the search because text indexes do not automatically traverse reference relationships.

 

Refer: https://developer.servicenow.com/blog.do?p=/post/dot-walking-in-the-rest-table-api-2/

https://www.servicenow.com/community/developer-forum/table-api-dot-walking-on-sysparm-query/m-p/2235...

https://www.servicenow.com/community/developer-forum/are-there-limits-on-dot-walking-in-sysparm-quer...

 

Please Accept the solution if it assisted you with your question & Mark this response as Helpful.
Regards
Tanushree Maiti
ServiceNow Technical Architect
LinkedIn: https://www.linkedin.com/in/tanushreemaiti

Hi,

 

how do i find the fields indexed for a table?