Open Rishika-Shrivastava opened 1 year ago
Hi, Here is the jolt transformation for your question.
jolt transformation:-
[
{
"operation": "modify-overwrite-beta",
"spec": {
"data": {
"event_name1": "=split(' ',@(1,event_name))",
"event_name": "=join('_',@(1,event_name1))"
}
}
},
{
"operation": "remove",
"spec": {
"data": {
"event_name1": ""
}
}
}
]
Explanation:-
I am using the field event_name to create a kafka topic.
I need to remove all the spaces or replace them with underscores.
"event_name": "Menu item clicked" should look like "event_name": "Menuitemclicked" or "event_name": "Menu_item_clicked". How can I achieve that?