Using Any Filter
Any Filter Criteria
Any Filter Speed
Using By Date
(Synonyms; new fields; Clear option)
Try these plugins:
PSB Quick Look
Any Filter provides search capabilities similar to Smart Collections but with many more searchable photo fields (criteria) and many more operators for comparing fields. Search over any photo field or setting that’s visible in Lightroom and many that aren’t, including IPTC Extension, GPS location, library properties, develop settings, and plugin fields (340 fields in all). Additional operators include exact text match, matching regular expressions, testing empty fields, distinguishing explicit from implicit ancestor keywords, treating text fields as numeric, and including other saved Any Filters and Smart Collections.
Example Any Filters include:
Any Filter also provides a command that lets you quickly filter by dates and date ranges by typing the dates, rather than fussing with the Library Filter bar:
The free trial is for 30 days—after that, you’ll need to buy a license.Buy a License
Creating an Any Filter is very similar to creating a Smart Collection. If you’re not familiar with Smart Collections, I recommend you read the Adobe Help before trying to use Any Filter. Any Filter includes all the criteria of Smart Collections and adds many more.
Any Filter commands are available under Library > Plug-in Extras > Any Filter menu as well as File > Plug-in Extras > Any Filter. Their location under File allows them to be used in any module, while the Library menu is retained for users accustomed to earlier versions of Any Filter.Applying a Saved Any Filter
When you apply a saved Any Filter, all the images in the catalog are filtered to show just the ones matching the Any Filter. Unlike Smart Collections, the results aren’t automatically updated as you change images – reapply the filter to see new results.
To apply a saved Any Filter:
Each time you apply an Any Filter, the resulting photos are saved in a new collection under the collection set Any Filter Results. Any Filter retains the most recent 8 results. If you want to retain one of the collections permanently, rename it or move it to another collection set. You can disable saving of results by unchecking the option Save results as a collection.Applying a Collection or Smart Collection
As a convenience, you can filter using an existing collection or Smart Collection rather than a saved Any Filter. This lets you view the contents of a collection with all the contained stacks collapsed (Lightroom doesn’t show stacking for collections). It also lets you snapshot the contents of a Smart Collection, which is handy when you don’t want the set of images matched by the Smart Collection to automatically update as you modify them. And it lets you intersect the results of a smart collection or collection with a folder, functionality that was removed from Lightroom 4.
Creating and editing an Any Filter is similar to creating a Smart Collection:
Any Filter can search custom metadata fields defined by plug-ins. To tell Any Filter to search a plug-in’s fields:
When editing an Any Filter, the plug-in will now be listed in the left-most drop-down menu along with the other categories of criteria (Library, Date/Time, Description, etc.).
Plug-ins that store numbers in their metadata fields store the numbers as texts, but you can use Any Filter’s numeric operators (< number, = number, etc.) to treat those fields as numeric.Any Filter Criteria
Any Filter provides all of the searchable photo fields (criteria) and operators of Smart Collections and many more, including IPTC Extension, GPS location, library properties, develop settings, and plugin fields. The complete list is available here. Additional operators include exact text match, matching regular expressions, testing empty fields, distinguishing explicit from implicit ancestor keywords, treating text fields as numeric, and including other saved Any Filters and Smart Collections.
The matches and doesn't match operators test whether a field's value matches a pattern. The pattern syntax is documented here.
Any Filter provides more flexibility with fields like Collections and Keywords that contain multiple values. As with Smart Collections, you can define a criterion Keywords = John that matches a photo if at least one of its keywords is equal to John. But you can also define that criterion more explicitly as:
Keywords some items
which is true if at least one of the keywords is equal to John. Similarly, the criterion Keywords != John matches if none of the keywords matches John; this is equivalent to:
Keywords no items
Using this explicit testing of individual items, you can write more complicated criteria:
Keywords all items
This matches a photo if all of its keywords are either John or Peter. See the predefined Any Filter Exactly one person in the keywords for how to write a more complicated filter that matches photos that contain exactly one person (a subkeyword of People) and no others.
Some of the IPTC Extension fields are actually sequences of multiple subfields. For example, the Locations Shown field can contain one or more locations, each of which has a City, Country Code, Country, Province/State, Sublocation, and World Region. To match photos showing the location Palo Alto, CA:
Locations Shown some items
For any field with multiple values, you can test the number of values using the number of operators. For example, to match photos with no more than 2 explicit keywords assigned:
Explicit Keywords number of <= 2
Lightroom’s Smart Collections and filtering define the Keywords criterion to mean any keywords that have been explicitly applied to the photo, the corresponding ancestor keywords, and any synonyms of those keywords. For example, if the keyword People > Family > John has been applied to a photo, then the Smart Collection Keywords contains People will match that photo.
With Any Filter’s Explicit Keywords criterion, you can match the explicitly applied keywords only, ignoring synonyms and the implicit ancestor keywords. You can use the subkeyword of operator to test if an explicit keyword is a subkeyword or identical to another keyword. For example, the criterion Explicit Keywords subkeyword of People is the same as Keywords = People. See the predefined Any Filter Exactly one person in the keywords for an example.
The criterion Explicit Keywords contains ancestors has a unique purpose, to identify a photo that has both a keyword and its ancestor explicitly applied, for example, People and People > Family > John. This can be handy when you’re adding more levels of detail to your keyword hierarchy and want to find photos where you've accidentally applied both a keyword and its ancestor.
Some Any Filters match photos as fast as Smart Collections, some match as slow as 150 photos/second (if they access develop settings), and most will match at least 1500 photos/second, often many times faster. Any Filter is limited by the speed at which Lightroom supplies plug-ins with photos’ metadata.
Wherever possible, Any Filter uses Smart Collections internally to speed up matching. For example, to implement Keywords = John, Any Filter first executes Keywords contains John using Smart Collections (which is very fast) and then further filters the resulting photos to those whose keywords exactly match John.
If your Any Filter is matching too slowly, consider adding Smart Collection criteria that will help Any Filter quickly narrow down the set of photos. For example, if you know that the desired photos were captured in the last several months, add a Date/Time Original (Capture) criterion.
The By Date command lets you quickly filter by dates and date ranges by typing the dates, rather than fussing with the Library Filter bar. When prompted for a date, you can enter the full year/month/day, year/month, or just a year.
For example, to find all photos in 2012, select Date and enter 2012. To find all photos from 1993 to 1999, select Date Range and enter the years 1993 and 1999.
The option Clear current filter clears all previous filter conditions in the Library Filter bar; deselecting that option causes a Date column to be added to the current filter.
Windows: You can use the standard menu keystrokes to invoke Any Filter commands. For example, ALT+L opens the Library menu, U opens the Plug-in Extras submenu, and S invokes the Any Filter Search command.
To reassign a different final keystroke to an Any Filter menu item, edit the file Info.lua in the plugin folder. Move the & in front of the desired letter in the menu command’s name, changing the name itself if necessary.
Mac OS: You can use the standard mechanism for assigning application shortcuts to plugin menu commands. In System Preferences > Keyboard > Keyboard Shortcuts > Application Shortcuts, select Adobe Lightroom. Click "+" to add a new shortcut, in Menu Title type the name of the menu command preceded by three spaces. For example, if you wanted to assign a key to the Any Filter > Search command, type "<space><space><space>Search". In Keyboard Shortcut type the desired key or key combination.
Please send problems, bugs, suggestions, and feedback to
I’ll gladly provide free licenses in exchange for reports of new, reproducible bugs.
If Any Filter crashes with an error or produces surprising results, please check the Debug option and re-apply the filter. In the plug-in folder anyfilter.lrplugin, find the files debug.log and anyfilters.txt and email them to me. If you don’t remember the location of the folder, do File > Plug-in Manager, select Any Filter, and look at Path. On Mac OS, the folder won’t normally open in the Finder – right-click it and select Show Package Contents.
Known limitations and issues: