John AND Doe
This enhancement is in Beta please help by providing us your feedback!
SuiteCRM Elasticsearch engine makes use of Elasticsearch’s Query String DSL. This allows very advanced search query to be performed.
For a complete understanding check the official documentation. A quick overview will be provided here.
Search for all the records having both 'John' and 'Doe' in any field:
John AND Doe
Search for all the records having the first name 'John' (note that this won’t include 'Johnny'):
Search for all the records having with the name starting with 'John':
Search for all the Accounts having 'corp' in their name:
named:corp AND _type:Accounts
By default keywords are joined by OR clauses,
meaning that searching for
John Doe will be the same as searching for
John OR Doe.
Of course results containing both 'John' and 'Doe' will appear on top.
Names are boosted, meaning that if one of the keywords match in the name the record will very likely appear on top.
By default the entire keywords must match. Thus searching with 'John' won’t match someone named 'Johnathan'.
To do that you need to use a wildcard character.
* can be use interchangeably to replace zero or more characters.
? can be used to replace exactly one character.
Search for both 'John' and 'Johnathan':
Search for all the surnames starting with either 'Mc' or 'Mac':
name.last:(Mc* OR Mac*)
Wildcards can be used at the beginning of the keyword too, but it will make the search slightly slower.
Search for all the records having the last name ending with 'Connor':
You can restrict search to one or more module by using the
_type keyword and the module name.
Search for all the Users:
~ will make a keyword fuzzy, meaning that it will make a proximity search,
finding all matches that have one different character (distance).
The distance can be customised by adding a number after the tilde,
Search for 'MacKenzie', 'McKenzie', 'Makenzie', etc.
Each records has the following meta fields that can be searched:
Search all the records created by 'John Doe':
Search all the records modified on the first of August.
Content is available under GNU Free Documentation License 1.3 or later unless otherwise noted.