CartMetrix - Do you know yours?

« Selecting Filenames with Non-Standard Characters in the Filename from the Shell | Home | Todo.txt - A Command Line Task Tracker »

3/25/2007

Advanced OSX Mail Searches

When you live and breathe email for work and play, it can be quite important to keep messages around for reference. In my business, client and project specific correspondence is supremely important as a record of what has been done, what needs done and project cost quotes among other things. The important information usually gets copied into my bug tracker, project information database and billing applications, but there is just something about the chronological nature of email that helps me follow a project.

What’s the point of keeping email around if you can’t accurately find the messages you are looking for? Apple’s Mail application can be used to do some heavy lifting searches if you can think outside of the box a little. Below are some examples of the general boolean search available directly in Mail.

Heads AND Tails

heads & tails

Heads OR Tails

heads | tails

Heads but NOT Tails

heads ! tails

Heads AND either Tails OR Both

heads & (tails | both)

While researching these search options I found some users that reported that and, or and not worked as well. This is not listed in the Mail documentation and I was not able to confirm their usage. These did not work on my machine. For reference, I am running 10.4.9 and Mail 2.1 (752/752.2).

From the Mail help system:

If you search the From, To, or Subject fields in selected mailboxes, Mail finds messages that contain the entire search phrase, in the order you entered the words. If you search an entire message or search in all mailboxes, Mail finds only messages containing words that have the same prefix (or the same beginning letters) as any of the words you entered in the Search field. The words can be in any order. For example, if you enter “box” in the Search field, the results would include “boxcar” but would not include “mailbox,” because “box” is not part of the prefix in that word.

The help document also mentions that any IMAP accounts need to be configured to “Keep copies of messages for offline viewing”. This setting is configured from the Advanced tab of the Accounts pane in Mail Preferences. The default is to cache “All messages and their attachments.” I use “All messages but omit their attachments.” I would like to use “Only messages I’ve read,” as that would omit all of the uncaught spam and messages that get deleted without being read, but from my tests that option still caches the attachments. I think caching attachments is a waste of bandwidth and local disk space, plus it doesn’t fit in with my normal usage. When I get an important attachment, I download it to a local folder, either a client folder to keep with the rest of the client data or to my general downloads folder where it can be dealt with and deleted when no longer needed.

I have been using a beta version of MailTags for a month now and am finding it more and more invaluable in tracking project and client emails. It adds customizable fields to messages so may easily tag a message with a project name or add notes to a message and adds to the built-in Mail search so you can search by these tags specifically. It also integrates nicely with OSX’s Calendar application, allowing you to create To Do items directly from the MailTags pane in a message.

Another searching option is to create a Smart Mailbox with your search parameters. Smart Mailboxes can be used to mix and match multiple search parameters in the same search. Don’t be shy about creating a Smart Mailbox to do a one-off search. Wouldn’t it be faster to create a Smart Mailbox, use it to find your messages and delete it afterwards than to manually search for a message for twenty minutes? You can also create a Smart Mailbox to pre-select a group of messages, say by including all messages from all of the parties involved in a particular project and then using Mail’s basic search over that Smart Mailbox to find only those messages that contain a particular keyword.

There are some shortcomings I find in Mail’s search and Smart Mailbox implementations. My biggest beef is that Mail won’t let you Cmd-select multiple locations to do a keyword search over. For instance, you cannot search for an email address that appears in the From or To fields. You can do separate searches for both and manually merge them in your head or setup a Smart Mailbox to do the task.

The Smart Mailbox implementation is also crippled in that you can only select messages by all the criterion you supply or by any single criteria not some of these but none of those. This can be overcome by using multiple Smart Mailboxes, one to select all of the messages you want and a second mailbox to deselect the ones you don’t need that happen to fall in to the first mailbox.

Say you would like all messages from a particular domain except the general address info@domain.com. First create the deselect mailbox that finds all messages from info@domain.com, then create a second Smart Mailbox that selects all messages from domain.com and add a second criteria to it that says “Mail is not in mailbox” and choose the deselect Smart Mailbox you created. This is a simplistic example that can be overcome by creating a box that manually selects all messages from user1@domain.com … userN@domain.com, but that would require you to know all of the addresses and key them in.

All in all Mail’s searching implementation is powerful if you know the right tricks. Have some more Mail search tricks? Post via the comments below.

Popularity: 31%

Trackback:

Related Posts

Post your opinion

Verification Image

Please type the letters you see in the picture.

Subscribe without commenting


damonparker.org is proudly powered by WordPress
Entries (RSS) and Comments (RSS).

copyright © 2002-2008 damonparker.org. all rights reserved.

Close
E-mail It