[TD_SYSFNLIB.] JSON_KEYS (
ON (json_expr)
[ USING name_value_pair [...] ]
) [AS] correlation_name
Syntax Elements
-
name_value_pair
-
{ DEPTH | QUOTES } (value)
- TD_SYSFNLIB
- The name of the database where the function is located.
-
json_expr
- An expression that evaluates to correct JSON syntax. The expression can be a CHAR, VARCHAR, CLOB, or JSON representation of a JSON data type in LATIN or UNICODE.
- AS
- An optional keyword introducing correlation_name.
-
correlation_name
- An alias for the input column specified by the ON clause.
- ANSI SQL refers to aliases as correlation names. They are also referred to as range variables.
- DEPTH
- An optional clause that restricts the depth of the search. value is a positive integer that specifies the maximum depth for the search.
- The default value is the maximum depth of the JSON instance.
- For example, setting the depth to 1 gets the top level keys in the JSON instance.
- QUOTES
- An optional clause that specifies whether or not the key names in the result are enclosed in double quotation marks as follows:
- If value is 'Y' or 'y', the key names in the result are enclosed in double quotation marks. This is the default if the USING QUOTES clause is not specified.
- If value is 'N' or 'n', the key names in the result are not enclosed in double quotation marks.