Examples of Functions

These functions are used in the attribute formulas.

Note: User role: Product Administrator

COUNT

COUNT(status=open,severity=low)

This example counts the number of 'low severity' issues that are 'open'. COUNT can only be used with filters in a formula.

IF

IF(businessimpact > 2, 5,1)

This example determines that if the 'businessimpact' value is greater than 2, the value to use in the formula is 5. If 'businessimpact' is less than 2, the value to use in the formula is 1. IF can only be used with values in a formula.

MAX

MAX(severity, status=open)

This example returns the maximum of all the severities that are 'open'. MAX can be used only with filters in a formula.

Table 1. Filter option values to use with MAX

Filter option values to use with MAX

Filter Option Numeric value to use in formula
Classification Definitive 1
Suspect 2
Severity High 4
Medium 3
Low 2
Information 1
Status Open 1
InProgress 2
Reopened 3
Noise 4
Passed 5
Fixed 6
New 7
Discovery Method DAST (Dynamic Analysis) 1
SAST (Static Analysis) 0