Supported list types

Number list

This function returns a number list with distinct elements from two lists.

Syntax
union(numberList1, numberList2) #Output: Number list
Examples
Parser expressionDescription
%{union([1, 2, 3], [3, 4, 5])}

This example returns

1, 2, 3, 4, 5

%{union(toNumberList(%{issue.versions.id}),toNumberList(%{issue.fixVersions.id}))}

This example returns a distinct number list of both affected and fix version/s id/s of the current issue, e.g. 

10002,10000,10001 

To achieve this, the following functions are used:

Additional information

Parameters used in this function

ParameterInput (data type)Description
numberList1

NUMBER LIST

Any given number list.
numberList2

NUMBER LIST

Any given number list.
Output

This function returns a NUMBER LIST


Text list

Variant for text lists.

Syntax
union(textList1, textList2) #Output: Text list
Examples
Parser expressionDescription
%{union(["blue", "red", "green"], ["red", "green", "yellow"])}

This example returns

blue, red, green, yellow

%{union(toStringList(%{issue.versions}),toStringList(%{issue.fixVersions}))}

This example returns a distinctext list of both affected and fix version/s of the current issue, e.g. 

1.1,1.0,2.0 

To achieve this, the following functions are used:

Additional information

Parameters used in this function

ParameterInput (data type)Description
textList1

TEXT LIST

Any given text list.
textList2

TEXT LIST

Any given text list.
Output

This function returns a TEXT LIST


Issue list

Variant for issue lists.

syntax
union(issueList1, issueList2) #Output: Issue list
Examples
Parser expressionDescription
%{union(linkedIssues(), subtasks())}

This example returns the issue list of linked issues and sub-tasks of current issue, without duplicates.

To achieve this the following functions are used:

Additional information

Parameters used in this function

ParameterInput (data type)Description
issueList1

ISSUE LIST

Any given issue list. Usually this value is retrieved from a function (e.g. linkedIssues() or subtasks()).
issueList2

ISSUE LIST

Any given issue list. Usually this value is retrieved from a function (e.g. linkedIssues() or subtasks()).
Output

This function returns an ISSUE LIST