JSON_ARRAY¶
JSON_ARRAY constructs a JSON array from a list of data.
- value
-
Specifies one or more constants, table columns, or expressions. Only 100 values can be used in a single JSON_ARRAY statement.
- NULL ON NULL | ABSENT ON NULL
-
Specifies how nulls are handled. NULL ON NULL inserts nulls as SQL nulls. ABSENT ON NULL omits null values. Default is ABSENT ON NULL.
- RETURNING datatype
-
Specifies the data type of the result. Datatype can be any string data type. Default is varchar(4000).
Example:
returns: