Amazon Redshift will no longer support the creation of new Python UDFs starting November 1, 2025.
If you would like to use Python UDFs, create the UDFs prior to that date.
Existing Python UDFs will continue to function as normal. For more information, see the
blog post
array function
Creates an array of the SUPER data type.
Syntax
ARRAY( [ expr1 ] [ , expr2 [ , ... ] ] )
Argument
- expr1, expr2
-
Expressions of any Amazon Redshift data type except date and time types, since Amazon Redshift doesn't cast the date and time types to the SUPER data type. The arguments don't need to be of the same data type.
Return type
The array function returns the SUPER data type.
Example
The following examples show an array of numeric values and an array of different data types.
--an array of numeric values select array(1,50,null,100); array ------------------ [1,50,null,100] (1 row) --an array of different data types select array(1,'abc',true,3.14); array ----------------------- [1,"abc",true,3.14] (1 row)