Skip to content

Wildcard searching in SugarCRM

SugarCRM

So we have a simple tip today…how to do wildcard searching in Sugar in text fields, maybe in multiple fields. This is an easy one to explain, but not immediately obvious to someone that hasn’t used Sugar before and to people that aren’t familiar with the LIKE command in SQL statements.

Show me..

So, firstly you want to search on an account name record and want to pull up anything which has North at the beginning. This is as simple as entering:

North%

Into the Account Name search box on the View Accounts screen or by entering this in the Global search box on the top right.

But what if you want to search for anything with the word North at e end of the field?

%North

…is your answer…

…and what if I want to find the North anywhere in the field…I don’t mind where it is?

%North%

…is your answer…

Enjoy..

2 Comments Post a comment
  1. sts #

    The examples are not correct since Sugar always adds a ‘%’ to the end of the search string … So you can search for “North” to find everything beginning with “North” and “%North” to find everything containing “North” anywhere in the field.

    (It is off course possible to add a ‘%’ at the end of the string, but it is not needed.)

    March 27, 2012
    • Simon Chapman #

      Correct. I was showing the wildcards altogether for ‘completeness’. You’re right, Sugar does attach a % to the end of each search string.

      April 4, 2012

Leave a Reply

You may use basic HTML in your comments. Your email address will not be published.

Subscribe to this comment feed via RSS