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

How to set a list search to "contains" without changing the property.

nanamimakin
Kilo Expert

Regarding list searches, I am unable to modify the environment properties of the system under development,

but I would like to configure the search to use a "contains" (includes the value) match.
The linked documentation describes a method for configuring default search behavior for dictionary properties—specifically by setting `goto_use_starts_with=true` to enable a "starts with" match—but I do not wish to modify properties or use wildcards (such as `*`) to achieve a "contains" match in a similar way.

nanamimakin_0-1783416252973.png



https://www.servicenow.com/docs/r/ja-JP/platform-user-interface/t_SearchAList.html

4 ACCEPTED SOLUTIONS

Tanushree Maiti
Tera Patron

Hi @nanamimakin 

 

Enable contains auto-complete searches

By default, the reference auto-complete uses a starts with search. A user preference can be created to implement a contains search.

Before you begin

Role required: admin

Procedure

  1. Disable the glide.ui.ref_ac.startswith system property.
    For more information, see Improve auto-complete queries.
    Note:
    Setting the glide.ui.ref_ac.startswith system property to true overrides any existing "autocomplete.contains" settings in both user and system level preferences. This property changes the auto-complete query method for all users regardless of preferences.
  2. Navigate to User Administration > User Preferences.
  3. Select the preference "'<referenced table>.autocomplete.contains"'.
  4. Set the value field to true.
  5. Select Update.

What to do next

Log out and log back in to display the updated search.
 
Also check: Search a list 
 
 
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

View solution in original post

nanamimakin
Kilo Expert

@Tanushree Maiti 
Thank you for your reply.
The method you suggested would require changing property settings.
I would like to avoid changing settings, so that approach is not feasible.
I want to limit the scope to specific columns in a custom table,
rather than affecting the entire environment.

View solution in original post

yashkamde
Mega Sage

Hello @nanamimakin ,

 

By default, list search behavior is controlled by system properties.

Also ootb, there is no supported configuration to make the global list search perform a Contains match by default without modifying system properties.

 

Although you can also rely on wildcards (for example *value).

 

If my response helped mark as helpful and accept the solution.

View solution in original post

Ankur Bawiskar
Tera Patron

@nanamimakin 

not possible without updating system property

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

4 REPLIES 4

Tanushree Maiti
Tera Patron

Hi @nanamimakin 

 

Enable contains auto-complete searches

By default, the reference auto-complete uses a starts with search. A user preference can be created to implement a contains search.

Before you begin

Role required: admin

Procedure

  1. Disable the glide.ui.ref_ac.startswith system property.
    For more information, see Improve auto-complete queries.
    Note:
    Setting the glide.ui.ref_ac.startswith system property to true overrides any existing "autocomplete.contains" settings in both user and system level preferences. This property changes the auto-complete query method for all users regardless of preferences.
  2. Navigate to User Administration > User Preferences.
  3. Select the preference "'<referenced table>.autocomplete.contains"'.
  4. Set the value field to true.
  5. Select Update.

What to do next

Log out and log back in to display the updated search.
 
Also check: Search a list 
 
 
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

nanamimakin
Kilo Expert

@Tanushree Maiti 
Thank you for your reply.
The method you suggested would require changing property settings.
I would like to avoid changing settings, so that approach is not feasible.
I want to limit the scope to specific columns in a custom table,
rather than affecting the entire environment.

yashkamde
Mega Sage

Hello @nanamimakin ,

 

By default, list search behavior is controlled by system properties.

Also ootb, there is no supported configuration to make the global list search perform a Contains match by default without modifying system properties.

 

Although you can also rely on wildcards (for example *value).

 

If my response helped mark as helpful and accept the solution.

Ankur Bawiskar
Tera Patron

@nanamimakin 

not possible without updating system property

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader