Show TOC Start of Content Area

Function documentation Property Search Locate the document in its SAP Library structure

Use

The property search enables applications to retrieve resources on the basis of properties and their values. It is implemented with queries that specify the property values of the resources that are to be retrieved. The search is recommended for operations within a collection, but not for deep searches through several levels of a hierarchy or across several repositories.

Note

The property search does not use Search and Classification (TREX). It relies on mechanisms provided by the repositories. Unlike TREX, which can search content, the property search can only return properties and their values.
The result of a property search is always up-to-date, whereas the result of a TREX search may be outdated, depending on the TREX configuration and update intervals.

Features

Similarly to SQL, where a SELECT expression returns a list of records that match the SELECT expression’s WHERE clause, a property query expression returns a list of resources that match the query expression. A query expression is constructed with the help of a query builder. The following example shows a query expression that returns all resources created by the admin user and have a content type ending in jpg or gif:

(   ‘{http://sapportals.com/xmlns/cm}contenttype’ like ‘%/jpg’
 or ‘{http://sapportals.com/xmlns/cm}contenttype’ like ‘%/gif’)
and ‘{http://sapportals.com/xmlns/cm}createdby’ like ‘admin’

When the expression is executed, further parameters are specified, for example, a start resource (collection) that defines in which sub-tree of the hierarchy the search must begin and the number of levels to search in the sub-tree. Available parameters for specifying the search levels are:

     Depth specifies how many levels of parent-child hierarchy to search

     0 returns only the start resource if it matches the given query expression

     1 returns the start resource and all the children that match the given query expression

     Infinite returns a list of matching resources for the entire hierarchy below the given start resource

A property search does not follow links. This ensures that only the resources in the specified sub-tree within the same repository are found.

See also:

Searching with Properties

End of Content Area