Create Complex Searches in Spotlight

You can do complex boolean searches in spotlight’s search field by including parenthesis, AND, and OR statements. Unfortunately, a lot of metadata is not available via Spotlight’s keyword searches, but is available via the Finder’s search window as “Other” criteria. Luckily, you can add boolean operators using the Find window and an undocumented trick.

If you hold down the option key while clicking the “+” button in the search criteria (it will change from “+” to “…”) to add a boolean operator (any of, none of, all of) and can nest these operators and other criteria as deeply as you want to.

The new version of Spotlight is also quite a bit faster when dealing with these complex queries, so you can go nuts.

If you’re wondering, the search shown above will find any files that either have a red or orange label or which are neither folders, aliases nor documents that have been opened in the past day or modified in the past week. I use this search as a “Current Projects” folder.

Twitter, Facebook

Written on October 30, 2007