- Categories:
AS_ ARRAY¶
Casts a VARIANT value to an ARRAY value.
- See also:
Syntax¶
Arguments¶
variant_exprAn expression that evaluates to a value of type VARIANT.
Returns¶
The function returns a value of type ARRAY or NULL:
- If the type of the value in the
variant_exprargument is ARRAY, the function returns a value of type ARRAY.
- If the type of the value in the
variant_exprargument doesn’t match the type of the output value, the function returns NULL. - If the
variant_exprargument is NULL, the function returns NULL.
Usage notes¶
- This function doesn’t support a structured type as an input argument.
Examples¶
Create a table and load data into it:
Use the AS_ARRAY function in a query to cast a VARIANT value to ARRAY values: