Tuesday, March 21, 2017

GMail Search & Filters : Search Syntax + some filter examples to auto label emails


References:

Gmail Filters : Exhaustive Syntax Documentation

Some advanced Gmail Filter topics


1. Create Gmail Filter to auto label incoming emails:

Requirement:

When an incoming email is received the email shall be saved to a label .\AWork\Jobs\Insurance if the email contains the word Cigna and if the email was not sent from jdoyle@RDTECHN9OLOGIES.NET

(Create the label first if it does not exist)

How to Build step by Step:

Search:

from:(-jdoyle@jrdtechnologies.net) Cigna


Filter:

image

2. Gmail Filters Syntax


Gmail Filter Syntax Examples for and/or searching:

OR
     to:adam OR subject:iPhone
     is same as
     {to:adam subject:iPhone}


AND
     to:adam AND subject:iPhone
     is same as
     to:adam subject:iPhone
     is same as
     (to:adam subject:iPhone )
   
() parens -> AND
{} brackets -> OR
    


3. Create advanced Filter to auto label incoming emails:

e.g: I need to move emails from Inobx into, I want to move emails based on following requirements:

If incoming email contains the words job or opportunity or contract and email is NOT from a job site alert, then save email to .\AWork\Jobs


If incoming email contains the words job or opportunity or contract and email is NOT from a job site alert AND email has the word Melbourne in it, then save email to .\AWork\Jobs\Melbourne


If incoming email contains the words job or opportunity or contract and email is NOT from a job site alert AND email has the word remote or telecommute in it, then save email to .\AWork\Jobs\Remote



.\AWork\Jobs

(job | opportunity | contract) -{remote from:{alert@indeed.com alerts@ziprecruiter.com inmail-hit-reply@linkedin.com noreply@updates.freelancer.com noreply@updates.freelancer.com info@mail.glassdoor.com noreply@glassdoor.com dartcontainer-jobnotification@noreply.jobs2web.com}} -in:chats


Looks like this:

image


.\AWork\Jobs\Melbourne

Search:

((remote | telecommuting | telecommute | remoting) -from:{jdoyle@jrdtechnologies.net alert@indeed.com alerts@ziprecruiter.com inmail-hit-reply@linkedin.com noreply@updates.freelancer.com noreply@updates.freelancer.com info@mail.glassdoor.com noreply@glassdoor.com dartcontainer-jobnotification@noreply.jobs2web.com})

Filter:

image


.\AWork\Jobs\Remote

Search:

((remote | telecommuting | telecommute | remoting) -from:{jdoyle@jrdtechnologies.net alert@indeed.com alerts@ziprecruiter.com inmail-hit-reply@linkedin.com noreply@updates.freelancer.com noreply@updates.freelancer.com info@mail.glassdoor.com noreply@glassdoor.com dartcontainer-jobnotification@noreply.jobs2web.com})


Filter:

image

When saving a filter be sure to use these options to move an email to a label:

image


3. Google Search by date:

image

 

4. Why Searching using Wildcard in Gmail doesn’t work and some alternatives

https://www.labnol.org/internet/advanced-gmail-search/21623/

http://sirlagz.net/2015/04/27/searching-gmail-with-wildcards/

(online2|online3|online4).provider.com