Hari Haran R
10/19/2024, 5:21 AMuser
10/19/2024, 5:21 AMjson { "type": "add", "path": ["object", "new_field"], "value": "{{ record['outside_field'] }}" }
In this example, object
is the path to the object where you want to add the new field, new_field
is the name of the new field, and outside_field
is the name of the outside field whose value you want to bring inside the object. Please note that this will not remove the outside field. If you want to remove the outside field, you can use a "remove" transformation. For more information, you can refer to the [Airbyte documentation on transformations](https://docs.airbyte.com/connector-development/connector-builder-ui/record-processing#transformations).Hari Haran R
10/19/2024, 5:25 AM[
{
"2024-10-01": [
{
"contactsPerPageview": 0.05319148936170213,
"returningVisits": 33,
"rawViews": 188,
"standardViews": 188,
"sessionToContactRate": 0.07518796992481203,
"pageviewsPerSession": 1.413533834586466,
"nonContactSubmissions": 12,
"visits": 133,
"visitors": 100,
"submissionsPerPageview": 0.06382978723404255,
"pageviewsMinusExits": 188,
"submissions": 12,
"leads": 10,
"leadsPerView": 0.05319148936170213,
"contacts": 10,
"newVisitorSessionRate": 0.7518796992481203
}
],
how to bring the date inside transformation @kapa.aiuser
10/19/2024, 5:25 AMuser
10/19/2024, 5:26 AMjson { "stream": { "transformations": [ { "type": "AddFields", "fields": [ { "path": ["date"], "value": "{{ stream_slice['2024-10-01'] }}" } ] } ] } }
In this example, date
is the name of the new field, and stream_slice['2024-10-01']
is the value of the date. Please note that this will not remove the date from the outside. If you want to remove the date from the outside, you can use a "remove" transformation. For more information, you can refer to the [Airbyte documentation on transformations](https://docs.airbyte.com/connector-development/connector-builder-ui/record-processing#transformations).Hari Haran R
10/19/2024, 5:30 AM[
{
"2024-10-19": [
{
"visits": 4,
"visitors": 2,
"pageviewsMinusExits": 4,
"returningVisits": 2,
"rawViews": 4,
"standardViews": 4,
"pageviewsPerSession": 1,
"newVisitorSessionRate": 0.5
}
],
"2024-10-20": [
{}
],
"DATE": "stream_slice['2024-10-19']"
}
]
@kapa.ai this is my responseuser
10/19/2024, 5:30 AMuser
10/19/2024, 5:31 AMHari Haran R
10/19/2024, 7:40 AMuser
10/19/2024, 7:40 AMuser
10/19/2024, 7:40 AMHari Haran R
10/19/2024, 7:41 AMuser
10/19/2024, 7:41 AMuser
10/19/2024, 7:41 AM