Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table plus
applyColStyleToCelltrue
columnTypess,s,s,s
heading0
multiplefalse
columnAttributesstyle="background:#e5e7ea;font-weight:bold,,style="background:#e5e7ea;font-weight:bold,
enableSortingfalse

Syntax

arrayAddElementIfNotExist(arrayName, elem)

Package

array

Alias

addElementIfNotExist(arrayName, elem)

Pkg Usage

addElementIfNotExist(arrayName, elem)

Description

Excerpt
hiddentrue

If elem is an element of the array type, returns a new array that includes the specified element at the end. The element is added only if it is not already in the array.

If elem is an element of the array type, returns a new array that includes the specified element at the end. The element is added only if it is not already in the array.

...

Table plus
applyColStyleToCelltrue
columnTypess,s,s,s
heading0
multiplefalse
enableSortingfalse

Parameter name

Type

Required

Description

arrayName

Array

Yes

Array the new element is added to.

elem

Any

Yes

Element to be added. Must be the same type as the array type.

Return Type

Array

Examples

Example 1

...

The initial array will be modified as a result of the = operator and NOT of the routine call.

Note
  1. If arrayName is not defined as an array, the routine returns error.

  2. If elem is not the same type as declared in the array definition, the routine returns error.

See also

Filter by label (Content by label)
showLabelsfalse
max25
showSpacefalse
cqllabel = "array_routine" and space = currentSpace ( )
labelsarray_routines