Versions Compared

Key

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


Page properties
hiddentrue
Status
Tech review

Status
colourYellow
titleReady for review

Style guide

Status
colourYellow
titleReady for review

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

Page properties
hiddentrue
Short description

Filters a number or text list using a given comparison.

Output StatussubtletruetitlelistAvailable since

Status
subtletrue
colourBlue
title2.1.23

Panel

Supported list types

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


Number list

UI Text Box
sizemedium
typeinfo

This function filters a number list using the given comparison.


Code Block
languagebash
titleSyntax
linenumberstrue
filterByValue(listnumberList, operator, number) #Output: Number list


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
filterByValue([1, 2, 3, 10, 11, 25, 100], >, 10)


This example returns a number list of values greater than 10 :   

[11, 25, 100]


Code Block
languagebash
linenumberstrue
filterByValue([1, 2, 3, 10, 11, 25, 100], <=, 10)


This example returns a number list of values less than or equal

to 

to 10

[1, 2, 3, 10]



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
listnumberList

Status
subtletrue
titlenumber list

Any given number list.
operator

Status
subtletrue
titleoperator

One of the allowed comparison operators.
number

Status
subtletrue
titleNumber

Any given number that will be used in combination with the operator to filter the given list.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titlenumber list



Text list

UI Text Box
sizemedium
typeinfo

This function filters a text list using the given comparison.


Code Block
languagebash
titleSyntax
linenumberstrue
filterByValue(listtextList, operator, text) #Output: Text list


UI Expand
titleExamples


Parser expressionDescription


Code Block
languagebash
linenumberstrue
filterByValue(["John", "Robert", "Kevin", "Mark"], ~, "r") 


This example returns a text text list of texts containing substring "r": 

["Robert", "Mark"]


Code Block
languagebash
linenumberstrue
filterByValue(["John", "Robert", "Kevin", "Mark"], !~, "r") 


This example returns a text list with all elements that don't contain the substring "r": 

["John", "Kevin"]


Code Block
languagebash
linenumberstrue
filterByValue(toStringList(%{issue.labels}), ~, "new") 


This example returns a text list with all labels from the current issue that contain the substring "new".

To achieve this, the following functions are used:



UI Expand
titleAdditional information

Parameters used in this function

ParameterInput (data type)Description
listtextList

Status
subtletrue
titletext list

Any given text list.
operator

Status
subtletrue
titleoperator

One of the allowed comparison operators.
text

Status
subtletrue
titletext

Any given text that will be used in combination with the operator to filter the text list.



UI Expand
titleOutput

This function returns a

Status
subtletrue
titletext list



Image AddedUse cases and examples

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


Page properties
hiddentrue
id1


Parser function cloudfilterByValue()
Map(tick)
Notes




Page properties
hiddentrue



Status
Tech review

Status
colourGreen
titledone

Style guide

Status
colourGreen
titledone

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



Page properties
hiddentrue


Short description

Filters a number or text list using a given comparison.

Output

Status
subtletrue
titlelist

Available since

Status
subtletrue
colourBlue
title2.1.23

Label

Status
colourRed
titlestaff pick