How-to Create Search Predicates For Assets On AEM 6.2, 6.3, 6.4


This can be used to extend the default search capabilities of assets on AEM Author.

Step-by-step guide

  1. Create a namespace, if you do not already have one.
    1. Go to http://localhost:4502/crx/explorer/index.jsp > Node Type Administration > Namespaces.
    2. For testing i created a new namespace.. URL: http://localhost:4502 ; Global Prefix: brand ; Session Prefix: brand (as below)
  2. Add your custom new metadata field to the default metadata profile. Or you can also create a new one.
    1. Go to AEM Tools > Assets > Metadata Schemas > default > select “image” > Edit
    2. I added a new Tab “Brand” for testing. You can also add a field to the default tabs as well.
    3. Add a “Single Line Text” from the “Build Form” tab on the right.
      1. Map to Property: ./jcr:content/metadata/brand:name( “brand” is the namespace )

  3. Add a new search predicate to the assets’s search form
    1. Go to AEM Tools > General > Search Forms > Select Assets Admin Search Rail > Edit
    2. Add a Multi Value Property Predicate to the form. Use the same “Property Name” as used in 2(c) above.  Save
  4. Add test metadata to the newly added field to some assets
  5. Test your search predicates.
    1. Go to AEM Navigation > Assets > Search (if on 6.3 then, AEM Navigation > Assets > Files > Search
    2. Enter some search term.. or blank and hit search
    3. Open filters.. you can see the newly added Brand Name search filter. Enter search term like Nike , preferably something that matches with test data in 4(a)


I have tested this on AEM 6.2 and 6.3