Useful Examples
17 min
search by e mail address use the \<font color="#eb144c">email addresses\</font> link to search all e mail addresses, not only the primary ones searching e mails by e mail addresses it is necessary to explicitly search the e mail address on the from , to , cc or bcc links here is an example of searching for \<font color="#eb144c">e mails\</font> having \<font color="#3b9f0f">"sarah"\</font> in either the from or to fields searching by tags search by the \<font color="#fcb900">name\</font> field on the \<font color="#eb144c">tags\</font> link searching for favorites search for records that have a non empty \<font color="#fcb900">favorite\</font> link searching for records that you follow search for records that have a non empty \<font color="#fcb900">following\</font> link searching multi select fields use the \<font color="#9900ef">contains\</font> operator searching for records related to a particular record to search for records related to a particular record, it is first necessary to determine the id of this particular record for instance, if you wanted to search for \<font color="#eb144c">calls\</font> related to \<font color="#eb144c">account\</font> abc inc , you would first need to find the id of abc inc you can learn how to do this in this faq docid\ w qrkderlew3wrpt zmuc once you've got the id, it's simply a matter of querying the id field on the appropriate relationship assuming the id of abc inc was \<font color="#3b9f0f">b582e48a b5ea 11ed 9a54 0242ac1b0002\</font> , this is how we would search for \<font color="#eb144c">calls\</font> that are related to this \<font color="#eb144c">account\</font> searching for my records there are two ways you can include a "my records" condition to your query, depending on what you need to achieve if you simply need to apply a query \<font color="#9900ef">and\</font> also filter the resulting records to only contain those assigned to you, you can simply use the existing \<font color="#2166ae">my records\</font> filter, which will automatically be combined with your query using \<font color="#9900ef">and\</font> if you need to build more complicated queries, such as involving \<font color="#9900ef">or\</font> , you will first need to find out the id of your user to do that, navigate to your profile, and copy it out of the address bar https //en wikipedia org/wiki/address bar it will be located right after records= , as seen in the picture below once you have that, you can search by the \<font color="#eb144c">assigned user name\</font> link, and combine it with whatever you need searching for other users' records in this case, the process is very similar to searching for your own records /#searching for my records you again have the option of combining your query with built in filters using \<font color="#9900ef">and\</font> alternatively, you can determine the ids of the users you need to search by as with your own id, this can be copied from the address bar https //en wikipedia org/wiki/address bar in the \<font color="#eb144c">employees\</font> module, after selecting the user you're interested in this can then be used analogously to searching for your own records /#searching for my records searching for minimal and maximal records using a trick, it is possible to retrieve records that are the "largest" or "smallest" by some numerical field for instance, you can use this to search for the most valuable \<font color="#eb144c">opportunities\</font> of each \<font color="#eb144c">account\</font> the trick relies on the fact that the largest/smallest record is always larger /smaller than or equal to all other records here's how you would list the most valuable opportunities of each account to find the least valuable opportunity, the query is analogous, except with \<font color="#9900ef">\<=\</font> searching for single records a similar trick to the one above /#searching for minimal and maximal records can be used to find records where only a single related record exists this trick relies on the fact that if there is only a single record, \<font color="#9900ef">\<all!\>\</font> record ids are equal to each other here are all \<font color="#eb144c">accounts\</font> which only have a single \<font color="#eb144c">opportunity\</font> careful, the \<font color="#9900ef">\<all!\>\</font> must be on the right hand side! docid\ kzbtllyb4xfj8df290vxi