remove() Function
This function may not be compatible with all features of Appian. For details, see the Feature Compatibility section below.

Function

remove( array, index )

Removes the value at a given index from an array, and returns the resulting array.

Parameters

Keyword Type Description

array

Any Type Array

The array to modify.

index

Integer or Integer Array

The one-based index or array of indices whose values should be removed.

Returns

Any Type Array

Usage considerations

Using the index parameter

The index value must be greater than or equal to 1.

Understanding results

Passing an empty array to the array parameter returns an empty array.

Passing an empty array to the index parameter returns the original array value.

Examples

Remove one value from an array

remove({10, 20, 30, 40}, 4) returns 10, 20, 30

Remove multiple values from an array

remove({10, 20, 30, 40},{2, 4}) returns 10, 30

Pass an empty array of indices

remove({10, 20, 30, 40}, {}) returns 10, 20, 30, 40

remove(null, {}) returns null

Feature compatibility

The table below lists this function's compatibility with various features in Appian.
Feature Compatibility Note
Portals Compatible
Offline Mobile Compatible
Custom Record Field Expressions Compatible
Open in Github Built: Fri, Aug 19, 2022 (02:35:57 PM)

On This Page

FEEDBACK