The ARRAY_FIRST function returns the minimum array index value of the array.
The data type of the result is the data type of the array index, which is INTEGER for an ordinary array. If array-variable is not null and the cardinality of the array is greater than zero, the value of the result is the minimum array index value, which is 1 for an ordinary array.
The result can be null; if array-variable is null or the cardinality of the array is zero, the result is the null value.
SET E_CONSTIDX = ARRAY_FIRST(SPECIALNUMBERS)
The result is 1.SET X = ARRAY_FIRST(PHONELIST)
The value of 'Home' is assigned to X.
Access the element value associated with index value 'Home' and assign it to the SQL variable NUMBER_TO_CALL:SET NUMBER_TO_CALL = PHONELIST[X]