Thank you for your feedback.
Form temporarily unavailable. Please try again or contact docfeedback@servicenow.com to submit your comments.
Versions
  • London
  • Kingston
  • Jakarta
  • Istanbul
  • Helsinki
  • Geneva
  • Store
Close

Change the query mode of an indexed table

Change the query mode of an indexed table

Set the query mode to specify whether searches on an indexed table must match all or only some of the search terms.

Before you begin

Role required: admin

To change the query mode of an indexed table, a text index must be present for the table. Make sure that text indexing is enabled for the table before changing the query mode. See Enable text indexing for a table.

About this task

Once a table is indexed, the data within the table can be searched through the global search bar. Change the query mode for the indexed table to allow global search to match all or only some of the searched terms. Enable a partial match rule to return results that partially match the searched terms.

Procedure

  1. Navigate to System Definition > Text Indexes.
  2. Select the table you want to configure from the list of indexed tables.
  3. Use the combo box to select a Default query mode.
    OptionDescription
    Default The default query mode for a table is an AND query.
    AND Matches all search terms.
    OR Matches one or more search terms.
    AND_OR Matches all search terms. If no results are found, matches one or more search terms.
  4. To enable partial matching of search terms, configure the partial match rule in the Partial Match Rule field.
    Partial match rules return results that partially match the search terms. Use a partial match rule if queries often include many keywords (if, for example, users cut and paste phrases into the global search bar).
    Table 1. Partial match rules
    Input type Example Description
    Integer 3 Indicates the minimum number of search terms to be matched.
    Negative integer -2 Indicates that the number of search terms, minus this number, should be matched.
    Percentage 75% Indicates the minimum percentage of search terms to be matched. The minimum number of search terms is the number computed from the percentage rounded down.
    Negative percentage -25% Indicates that the number of search terms, minus this percentage, should be matched. The minimum number of search terms is the number computed from the percentage rounded down and subtracted from the total number of search terms.
    Combination 3<70%

    A positive integer, followed by a less than symbol, followed by any of the previously mentioned input types. Indicates that if the number of search terms is equal to or less than the integer, all search terms are required. If the number of search terms is greater than the integer, the specification applies.

    In this example: if there are 1–3 search terms, all are required. If there are 4 or more search terms, only 70% are required.

    Multiple combinations 3<-25%, 9<-5

    Multiple conditional specifications separated by commas.

    In this example: if there are 1–3 search terms, all are required. If there are 4–9 search terms, all but 25% are required. If there are more than 9 search terms, all but 5 are required.

This site is scheduled for a small content update on Tuesday, December 18th, between the hours of 4:00pm and 8:00pm Pacific Time (Dec 19 00:00 – Dec 19 4:00 UTC). Access to this site may be slightly delayed during that time.