Define an Aggregate Expression
An Aggregate Expression is an Expression that calculates an Expression against child data in a Relationship (example: Counting the number of Incidents linked to a Problem).
To define an Aggregate Expression:
- Create an Expression.
- In the
Editor drop-down list, select
Aggregate.
The Aggregate Expression section opens.
- Define the Expression:
- In the
Relationship drop-down list, select a
Relationship
(example: Problem Has Linked Incidents).
Available Relationships are based on the associated Business Object (example: Problem).
- In the
Function drop-down list, select the type of
data you want to retrieve:
- Count: Number of Relationship occurrences (example: Number of linked Incidents).
- Total: Sum of a specified Numerical Expression.
- Average: Average of a specified Numerical Expression.
- Maximum: Highest returned value of a specified Numerical Expression.
- Minimum: Lowest returned value of a specified Numerical Expression.
- In the
Apply Against
drop-down list
Token Selector,
select the
Field or
Numerical Expression for which you want
to apply the Expression. This option is available for Total, Average, Maximum,
Minimum functions.
Tip: Create a Custom Expression on-the-fly by selecting New Custom Expression in the Token Selector.
- (Optional) Limit the
returned data using an additional Expression:
- Select the
Limit check box.
The Limit fields become active.
- Select an
Expression:
- Stored Expression: Select the ellipses button to open the Expression Manager, and then select an existing stored Expression or create a new stored Expression. Stored Expressions can be reused in numerous places in CSM.
- Custom Expression: Select the Custom Expression button to open the Custom Expression Builder, and then create a custom Expression specifically for this scenario.
- Select the
Limit check box.
- In the
Relationship drop-down list, select a
Relationship
(example: Problem Has Linked Incidents).
-
Select Save.