AI Search Index Source & Search Source Configuration for Task table

Brent Sutton
Mega Sage

I'm hoping this is a simple one to answer.

 

I'm trying to create an AI search indexed source and search source that will allow users to search for their active tasks via Employee Center portal.

 

Steps taken:

  1. Index Source - I've created an AI Search Index Source for the task table and restricted indexing to active "Change Request" and "Requested Item" task types (will be adding more later).
  2. Child Tables - Added the extended CHG [change_request] & RITM [sc_req_item] tables as child tables for the index source.
  3. Indexed all the tables.
  4. BrentSutton_3-1678226399439.png
  5. Search Source - Created a Search Source mapping with a condition to restrict users search results to ones they raised. The RITM "requested_for" and CHG "requested_by" fields are on the child tables linked to the indexed source. Encoded query below:

 

 

 

 

 

active=true^sys_class_name=sc_req_item^ref_sc_req_item.requested_forDYNAMIC90d1921e5f510100a9ad2572f2b477fe^ORopened_byDYNAMIC90d1921e5f510100a9ad2572f2b477fe^NQactive=true^sys_class_name=change_request^ref_change_request.requested_byDYNAMIC90d1921e5f510100a9ad2572f2b477fe^ORopened_byDYNAMIC90d1921e5f510100a9ad2572f2b477fe​

 

 

 

 

 

  1. Upon save of the search source I get an error "Search Source condition could not be saved. See logs for details." and "Invalid Insert" (see screenshot).
  2. BrentSutton_1-1678226213412.png
  3. When I look at the logs, I see an error message "dot-walk column doesn't exist task.ref_sc_req_item.requested_for" for RITM and "dot-walk column doesn't exist task.ref_change_request.requested_by" for CHG.
  4. BrentSutton_2-1678226293394.png
  5. I believe that a field setting may need to be created on the Indexed Source. However, there doesn't appear to be the option to use the dot-walk attribute for the task table or the ability to select child tables for the field selection.
  6. BrentSutton_0-1678226106541.png

     

I've looked at numereous support articles and ServiceNow docs trying to resolve this issue. I'm sure I'm not the first person to attempt indexing the Task table while restricting results using fields on child tables. Any guidance on how to achieve this, or suggestions for an alternative approach with a similar outcome, would be much appreciated.

11 REPLIES 11

Hey @Gerard Dwan, the issue isn't related to dynamic filters on the search source. It relates to adding conditions to the search source that only exist on the child table in the index.

I created a new example with the following:

  1. Created index for the Task [task] table.
  2. Added Request [sc_request] as the child table.
  3. Indexed all tables.
  4. Created Search Source using the task table index.
  5. Applied a non-dynamic filter condition to the search source which uses a field that is only available on the child table. In my example I used special_instructions which is only available on sc_request (child table in index). See encoded query below:

 

active=true^sys_class_name=sc_request^ref_sc_request.special_instructionsISNOTEMPTY​

 

  • Same error occurs - it appears to be related to the attribute only being available on the child table (it is not related to dynamic filters).
  • BrentSutton_0-1678992070721.png

     

I think there are a few special cases with the children of the task tables. I would recommend installing the AIS for Next Experience store app because the configuration closely aligns with what the best practices are around indexing the task table (and children). 

jokin
Tera Expert

Hi Brent, 

Did you resolve this issue? 

I experience the same behaviour/error when trying to configure similar conditions and have have  AIS for Next Experience store app istalled.

 

Best Regards

 

/Jonas

Brent Sutton
Mega Sage

Hi @jokin, this post goes back a while, but I don't think I got a solution to the issue. Not sure if anything has improved in subsequent ServiceNow releases to address this issue?

Brian Bakker
ServiceNow Employee
ServiceNow Employee

Out-of-box, we have Indexed Sources [ais_datasource] records for individual tables in the task hierarchy, such as incident, change_request, sc_request, problem, sc_task, and so on. For Now Experience in AI Search, we do not use a single indexed source on the [task] table with all the individual tables in the task hierarchy as child tables. The Platform allows you to create an Indexed Source on the [task] table, but all the task records returned in the search results will come under one results tab, instead of individual result tabs for each table in the task hierarchy, making it easier for users to find the record if they are searching for a specific table.