AlaaShaker's Weblog

// untitled …

Power Tips for better GMail Search!

leave a comment »

It happens a lot when you really need to do some sort of ‘advanced’ search in Gmail. It’s not always that a simple search does the job. How about some tips for using keywords that would make your life a lot easier?!

These are the keywords supported by GMail search:

from:
to:
subject:
cc:
bcc:
filename:
label:
after:
before:
has:
in:
is:

Now, let’s see each keyword:

  • from: { email address | name }
    Use from to search for an email from a specific person, either by their email address or simply their name.
    ex: from: Alaa Shaker – from: alaashaker@gmail.com
  • to: { email address | name }
    Use to to search for an email sent to a specific person, either by their email address or simply their name.
  • subject: { text | “exact text” }
    Use subject to search for emails with subjects containing the specified text, or containing an exact match to the text between the double quotes (case insensitive).
    ex: subject:my blog – subject:”my Blog”
  • cc: { email address }
    Use cc to find emails carbon copied to a specified recipient.
    ex: cc:alaashaker@gmail.com
  • bcc: { email address }
    Use bcc to find emails blind carbon copied to a specified recipient.
    ex: bcc:alaashaker@gmail.com
  • filename: { filename | extension }
    Use filename to find emails that have an attachment that matches the specified pattern, or simply provide an extension (.pdf, .doc, .bmp, etc.) to list all emails with attachments that belong to the same extension.
    ex: filename:mytextfile.txt – filename:pdf
  • label: { label-name }
    Use label to search for emails under a certain label
    ex: label:newsletters
  • after: { any known date format }
    Use after to search for emails sent or received after the specified date.
    ex: after:March 25 – after: 10/10/2007
  • before: { any known date format }
    Use before to search for emails sent or received before the specified date.

  • has:attachement
    Use has:attachement to search for emails with attachements.
    ex: has:attachement
  • in: { mailbox-folder }
    Use in to find emails in any of the Gmail mailbox folders: Inbox, Chats, Drafts, Trash, or Spam, or use the keyword ‘anywhere’.
    ex: in:chats
  • is: { read | unread | sent | starred }
    Use is to find read, unread, sent or starred email messages.
    ex: is:unread

So, I can eventually do some complex search as:label:newsletters is:unread subject:coding horror after:1/1/2008bringing me all email messages sent after the 1st of Jan, 2008, containing the words ‘coding’ and ‘horror’ in their subject, and are labeled under “Newsletters”.

Furthermore, you can use basic boolean operations, negation and grouping in your search. The only supported boolean operation is ‘OR’, as ‘AND’ is implicit. Use ‘-‘ for negation. Grouping is done using curved brackets'()’. as in:to:(sam mira) subject:(code OR executable) -label:projectswhich yields a search for all messages sent to Sam and Mira, with a subject containing the words ‘code’ or ‘executable’, and not labeled under “Projects”.

Now, if you use Firefox, enjoy searching your GMail using the default search toolbar after adding the Gmail search to it.

References: http://girishk.com/2007/04/21/gmail-search-syntax/ and http://philwilson.org/blog/2004/12/search-your-gmail-in-firefox.html

Advertisements

Written by AlaaShaker

May 2, 2008 at 6:28 am

Posted in Technology

Tagged with , ,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: