RECORD_TO_JSON
Converts a record to a JSON string. This function ignores fields calculated in LET statements and only considers fields from the source data.
Syntax
Arguments
Name | Type | Description | Default Value |
---|---|---|---|
record | record | The record you want to convert to a JSON string. |
Returns
Returns the JSON string representation of the provided record.
Example
Given a record:
Conversions:
RECORD_TO_JSON(fruits)
returns'["apple","banana","cherry"]'
RECORD_TO_JSON(user)
returns'{"first_name":"Jane","last_name":"Doe","location":{"city":"NY","country":"USA"}}'
RECORD_TO_JSON(user.location)
returns'{"city":"NY","country":"USA"}'
Transformation job example
Query result
fruits | user | location |
---|---|---|
|
|
|
Last updated