Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Panel

Supported list types

Table of Contents
exclude(Supported list types).*
stylecircle
typeflat
separatorpipe


Number list

UI Text Box
sizemedium
typeinfo

This function removes all duplicates from a number list.


Code Block
languagebash
titleSyntax
linenumberstrue
distinct(numberList) #Output: Number list


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
%{distinct([1, 2, 1, 3, 4, 4, 5])}


This example returns

1, 2, 3, 4, 5


Code Block
languagebash
linenumberstrue
%{distinct(append(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:



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
numberList

Status
subtletrue
titlenumber list

Any given number list.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titlenumber list
.

If the list is empty, the function returns an empty 

Status
subtletrue
titlenumber list
.



Text list

UI Text Box
sizemedium
typeinfo

This function removes all duplicates from a text list.


Code Block
languagebash
titleSyntax
linenumberstrue
distinct(textList) #Output: Text list


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
%{distinct(["blue", "green", "yellow", "blue", "yellow"])}


This example returns

blue, green, yellow


Code Block
languagebash
linenumberstrue
%{distinct(append(toStringList(%{issue.versions}),toStringList(%{issue.fixVersions})))}


This example returns a distinct text 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:



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
textList

Status
subtletrue
titletext list

Any given text list.



UI Expand
titleOutput

The function returns a

Status
subtletrue
titletext list
.

If the list is empty, the function returns an empty 

Status
subtletrue
titletext list
.



Issue list

UI Text Box
sizemedium
typeinfo

This function removes all duplicates from an issue list.


Code Block
languagebash
titleSyntax
linenumberstrue
distinct(issueList) #Output: Issue list


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
%{distinct(linkedIssues())}


This example returns an issue list of linked issues, with only one occurrence per issue, although an issue may be linked with more than one issue link type.

To achieve this, the following functions are used:



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
issueList

Status
subtletrue
titleissue list

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



UI Expand
titleOutput

This function returns an

Status
subtletrue
titleissue list
.

If the list is empty, the function returns an empty 

Status
subtletrue
titleissue list
.



Image AddedUse cases and examples

Page properties report
firstcolumnUse case
headingsJWT feature, Workflow function, Field type, Automated action, Parser functions
cqllabel = "parser_func_distinct" and space = currentSpace()


Page properties
hiddentrue



Status
Tech review

Status
titletodo

Style guide

Status
titletodo

Status
titletodo
Status
colourYellow
titleReady for review
Status
colourGreen
titledone
Status
colourRed
titleflagged



Page properties
hiddentrue


Short description

Removes all duplicates from a number, text, or issue list.

Output

Status
subtletrue
titlenumber list
 
Status
subtletrue
titletext list
 
Status
subtletrue
titleissue list

Available since

Status
subtletrue
colourBlue
title2.4.0

Label