Skip to main content

CHOOSE

Deprecated version

This document refers to a deprecated version of the RQL programming language.

Please go here for documentation related to the latest supported version.

Returns the item at the specified index from a list of values.

Syntax
CHOOSE(<int expression>, value1 [..., value n] )
Example
CHOOSE(2, "case 0", "case 1", "case 2") // "case 2"
CHOOSE(3, "case 0", "case 1", "case 2") // null
CHOOSE(1, 0, 1, 2, 3) // 1