Property search
Search has been enhanced with additional capabilities to search property values, starting with Cognos Analytics ( CA ) 12.0.4. This allows you to search your data module for objects by their properties. The existing search was restricted to the labels of objects.
An example of a property search would be searching for objects whose expressions contain a certain string. Another example would be searching for objects whose data type is a certain type.
You can search for both properties which contain text which you enter and for properties which contain enumerated (predefined) values, such as the usage or aggregate properties.
You can search to find objects which can have a property.
You can search to find objects where a property value has not been set.
Where property search is valid
The data module metadata tree
Relationship editor
Table editor (the editor for creating and editing views, aliases, shortcuts, copies, joined views, unions, intersects, and excepts.)
The expression editor’s selected data source and data source tabs.
Dashboard and exploration metadata tree
Properties which can be searched
Label
Identifier
Aggregate
Usage
Data type
Technical data type
Expression
Description
Comment
Screen tip
Syntax
:{property}:{search term}
This is a search for expressions where the string cast appears.
:expression:cast
The property value is case insensitive. For example, ‘label’, ‘LABEL’, ‘LABel’, ‘Label’, and any other combination of upper and lower case characters will be valid for the property term of the property search.
Search term is also case insensitive.
For properties which contain enumerated property values the search term will search for values which start with the specified string.
Partial property and search terms are accepted. For example, a search for objects with a usage property of identifier could be performed with :usage:identifier, :u:i or something in between.
If there are more than one property or enumerated property term which matches the search value the first property which is encountered will be used. For example, :aggregate:m will return all objects whose aggregate is maximum.
There can be cases where collisions between property values occur. For example, if you want to search for a data type of timestamp you need to type at least times before they will be returned. Before that only time data type values will be returned.
Examples of syntax
Search term
|
Result
|
:label:abc
|
Will search for objects that have a label containing the string abc.
|
:usage:summary
|
Will search for all objects whose usage property is set to summary.
|
:u:s
|
The same as the one above.
|
:aggregate:maximum
|
Will search for objects whose aggregate value is maximum.
|
:aggregate:ma
|
The same as the one above.
|
:a:ma
|
The same as the one above.
|
:a:m
|
Will search for objects whose aggregate value is maximum because it comes before minimum. (See the Partial matching resolution section below)
|
:a:mi
|
Will search for objects whose aggregate value is minimum
|
:usage::
|
Returns all objects which do not have a usage property set. By default, a query subject will not have its usage set. If that state exists, the query engine understands it as being the same as automatic.
|
:label:
|
Will search for objects that can have a label. This allows you to find properties which are undefined (which show up as ‘select an option’).
|
:label::
|
Will search for labels that are not set.
|
Localization
The property search uses the localized property values. For example, in English the property search of Data type:Integer would be :datentyp:ganzzahl in German.
Spaces
You can use spaces in the search.
Spaces are treated in a similar manner to characters.
In the examples below read the string {space} to be a space (i.e. the thing you enter when you press the space bar on your keyboard).
:des:{space}{space} will find any object whose description property has the two spaces space in it.
In the picture below you will see that there are two spaces after the last word in the description property, on the right, and the period. You will also see, on the left, :des: .
You can use a space in conjunction with other characters. For example, this search will look for Description properties where a period is followed by two spaces. If you had two spaces after the period, you could use this search to find comments where there are two or more spaces after a period. It could be that your house style requires one space after a period, so you would want to search for violations of that rule and correct it.
:Des:. {space}{space}
Partial matching resolution for properties with enumerated values
When you are searching a property, the search term you type will return all instances where that string exists. When you are searching a property which contains enumerated values, resolution rules apply determining what is returned.
If the search term is a partial match of two or more enumerated values, then the first ordered value will be used for the search term. This order is determined by the localized order of the terms.
:Data type:d
|
Will return objects whose data type is date as date precedes decimal.
|
In German :datentyp:d
|
Will return dates as dates (Datum) is before decimal (Dezimal)
|
:datatype:I
|
Will return integers as integer is before interval.
|
In German, :datentyp:I
|
Will return intervals as integer is ganzzahl in German and thus there is no ambiguity as to what search term is to be used.
|
:a:count
|
Will return all objects whose aggregate is count. :a:count If you put a space after the count all objects whose aggregate is count distinct will be returned.
|
Limitations
The property search is restricted to displaying the property values of objects which are visible in the metadata tree. As such, searching for the expression of an embedded filter which was created with the expression editor will not return a result.
Similarly, you cannot search for represents property values either.
You can’t escape the : character so you can’t search for a string which contains it. I was not able to discover this problem with any other character.
The relationship editor control to find tables does not support property search. Apparently, it isn’t the same class of object as the trees.