Breadcrumbs

Highest value out of several fields

📚

Return the highest value from a list of numbers consisting of a combination of numeric field codes.

Configuration

Create a Custom smart number field and use the General parsing mode.

Expression

%{max([{issue.cfAAAAA}, {issue.cfBBBBB}, {issue.cfCCCCC}, {issue.cfDDDDD}, 
{issue.cfEEEEE}])} 

Please, replace the field codes with the ones of your choice.

Display as

Number

Formatting style

Default (unformatted)

Used parser functions

The links lead to the JWTC documentation because the parser functions are shared functionalities.

Details

1. What does the expression do?

The expression returns the highest value from a list of numeric fields in a work item. In other words, it looks at several number fields and gives you the largest value among them.

2. Step-by-step breakdown

  • %{ ... }: This syntax is used to interpret the elements within as functions.

  • max(...): This is a parser function that finds the highest value in a list of numbers.

  • [ ... ]: The square brackets create a list of numeric values.

  • {issue.cfAAAAA}, {issue.cfBBBBB}, etc.: Each of these represents a numeric field in a work item. The codes (like AAAAA) are placeholders for your actual field IDs. You should replace them with the IDs of the numeric fields you want to compare.

3. Examples

Suppose you have three numeric fields in a work item:

  • Field 1 (cf12345): 10

  • Field 2 (cf67890): 25

  • Field 3 (cf54321): 17

If you use the expression:

%{max([{issue.cf12345}, {issue.cf67890}, {issue.cf54321}])}

The result will be 25, because that is the highest value among the three fields.

4. Real-life use cases

  • You want to track the highest score, cost, or value entered in several custom fields on a work item.

  • You have multiple numeric estimates (e.g., from different team members or sources) and want to display only the largest one.

  • You are aggregating risk, effort, or budget numbers from several fields and need to highlight the maximum value for reporting or decision-making.