Smart Folders

Smart Folders, introduced in mAirList 8.1, are virtual database folders whose contents are controlled by a search query instead of by manually assigned items. They are useful when you want a folder such as “all current news items”, “all tracks tagged for a particular show”, or “all items shorter than three minutes” to update automatically as the database changes.

What makes a folder smart?

A regular folder contains the items that have been assigned to it. A Smart Folder contains no manually managed list of items. Instead, mAirList stores a search query with the folder and evaluates that query whenever the folder contents are loaded or refreshed. Items that match the query appear in the folder; items that stop matching disappear from it automatically.

Because the contents are calculated, items cannot be added to or removed from a Smart Folder manually. To change its contents, edit the search query. To return to normal manual folder management, disable Smart Folder mode.

Smart Folders are available in mAirList Advanced, Advanced Plus, Advanced Server, and Professional. Existing installations may have to re-download the license in order to enable the feature. The folder configuration also requires the appropriate folder-management permissions.

Creating a Smart Folder

  1. Open the database browser and select the folder that should become smart.
  2. Open the folder configuration and select the Smart Folder tab.
  3. Click Turn this folder into a Smart Folder.
  4. Click Edit… in the Search Query section.
  5. Define the query and confirm the dialog.
  6. Save the folder configuration.

The folder configuration displays a readable summary of the current query. This summary is only a description; use Edit… to change the actual query. A blank query is not a useful Smart Folder query and produces no matching items.

Building the query

The query editor uses the same search concepts as Advanced Search. You can enter Keywords for a broad full-text search and then narrow the results with additional criteria:

  • Title, Artist, Comment, and End Type can use positive or negative text conditions.
  • Duration can specify a minimum, maximum, or both.
  • Ramp can filter by the position of ramp cue markers.
  • Standard attributes are added dynamically and can be searched as text, by range, or with is one of and is none of.

All filled-in criteria are combined with and semantics. For example, a query with Keywords set to news, a Duration maximum of 3:00, and an attribute condition Category is one of News; Bulletin returns only items satisfying all three parts. For details about the available conditions and full-text behavior, see here: Full Text Search and Advanced Search

How Smart Folders are evaluated

When mAirList loads a folder, the database backend evaluates the stored query and collects the IDs of all matching items. It then loads the matching item data in the same way as for an ordinary database result. Search limits are applied to the final result, not while the query is being assembled.

Smart Folders also work in folder hierarchies. When a folder is viewed recursively, mAirList includes manually assigned items from regular folders in the selected subtree and the results of Smart Folders in that subtree. This means a Smart Folder can contribute dynamically matching items to a recursive parent-folder view.

The query is evaluated again when the folder is reloaded, so changes to item metadata, attributes, duration, or cue markers are reflected after the database view is refreshed. The Smart Folder does not need to be rebuilt manually after each item change.

Examples

A current news folder

Set Keywords to news and optionally add Category is one of News; Bulletin. The folder will include items whose searchable information contains the keyword and whose Category attribute is one of the allowed values.

A short-music folder

Leave Keywords empty, set Duration maximum to 3:00, and add any desired attribute conditions. This creates a folder containing all items whose duration is no longer than three minutes and that satisfy the selected metadata filters.

An exclusion folder

Set an attribute to is none of and enter values such as Jingle; Sweeper. This selects items with that attribute set to another value, while items without the requested attribute are not considered matches for the exclusion condition.

Changing or disabling a Smart Folder

Open the folder configuration and use Edit… to replace the query. After saving, reload the database view to see the new result set. To make the folder regular again, click Disable Smart Folder and confirm the action. The stored search query is removed and the folder returns to manual item management.

Smart Folder definitions are saved as part of the folder configuration, so they remain associated with the folder when the database is used from another mAirList client that supports the feature.

4 Likes

I’ve chreated some test folders and I can say: It’s awesome!

Just a lil’ question: If I add the genre ‘Rock’ to ignore/exclude from the folder, will it exclude every genre that contains the word ‘Rock’, for example, ‘Hard Rock’ or ‘Progressive Rock’?

1 Like

As far as I understand from the description of the new advanced search, all items only matching complete attribute values.

1 Like