This procedure writes an array attribute of type sys.xmltype. The procedure uses a XSL transformation to generate JSON. To determine the JSON type of values, it uses the following rules:
If the value is empty, it generates a NULL value.
If upper(value) is TRUE, it generates a boolean true value.
If upper(value) is FALSE, it generates a boolean false value.
If the XPath number function returns TRUE, it emits the value as is. Otherwise, it enquotes the value (that is, treats it as a JSON string).
Syntax
APEX_JSON.WRITE (
    p_value    IN sys.xmltype );
Parameters
Table 15-42 WRITE Procedure Parameters
| Parameter | Description | 
|---|---|
| 
 | The value to be written. | 
Example
See "WRITE Procedure Signature 1".