Category: Web function
This function extracts a single value or a JSON object/array from a node specified by JSONPath.
Argument | Type | Description |
---|---|---|
JSON_text | Text | A string representing a JSON node. |
JSONPath | Text | The path to the JSON object/array to be returned. Learn more about the path syntax. |
Return value type: Any (The type of the value being returned.)
If a result is a JSON array, it's stripped of the wrapping square brackets in order to make further splitting more convenient (e.g. using Split delimited text into columns or Split delimited text into rows).
jsonvalue('{"customer":{"ID":345}}', 'customer.ID') //Returns 345 (Single scalar value)
jsonvalue('{"customer":{"ID":345, "name":"Plain Jane"}}', 'customer') //Returns '{"ID":345, "name":"Plain Jane"}' (JSON object)
jsonvalue('{"customerIDs":[345,346,347]}', 'customerIDs') //Returns '345,346,347' (JSON array stripped of brackets)