|
Is scripted source
|
Adds an advanced data fetch script. If configuring an instance table as the data source, do not check this option.
|
|
Data fetch script
|
Script defining the endpoint and API calls to fetch data. This field is only visible when **Is scripted source** is selected.
For an example of a data fetch script, see [Tutorial: set up an external knowledge base search source](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/platform-user-interface/service-portal/search-sp-advanced-ext-kb.md).
**Note:** If defining a facet generation script, inject the facets object into the data fetch script and update the script to generate data for each facet item. For an example, see the Knowledge Base and Service Catalog search sources. Search facets may not behave as expected if integrated into an advanced search source that queries data from a non- ServiceNow site.
|
|
Facet generation script
|
Script defining search facets for a scripted search source. Enable your end users to filter search results for a more meaningful result set. This field is only visible when **Is scripted source** is selected.
**Note:** If defining a facet generation script, inject the facets object into the data fetch script and update the script to generate data for each facet item. For an example, see the Knowledge Base and Service Catalog search sources. Search facets may not behave as expected if integrated into an advanced search source that queries data from a non- ServiceNow site.
|
|
Table
|
Select a table from the list that you want to draw your results from. You can select any table in the platform. For example, User \[sys\_user\] or Knowledge \[kb\_knowledge\]. **Note:** Only indexed tables return search results. Learn more: .
|
|
Conditions
|
Filters results based on defined conditions. For example, Active is True.
|
|
Primary display field
|
Select which field you want to display on the search results page. For example, Name.
|
|
Display fields
|
Select additional fields to display on the search results page. For example, User ID, Email, and City.
|
|
Paginate results
|
Paginates search results. True by default.
If **Is scripted source** is selected, the value updates to false. To enable pagination for a scripted search source, see [Paginate search source results](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/platform-user-interface/service-portal/paginate-scripted-search-source.md).
Define the maximum number of results per query for the search source in the Search Page widget or Faceted Search widget instance options.
|