Comma Separated String into Rows
Hello,
I have a requirement where a text with "," delimiter has to be generated into rows.
For Example a string or text $src_name = "AMK, ACK, AGK, ABK" should be generated as following rows.
The output should be separate rows as below.
AMK
ACK
AGK
ABK
I tried using the Group by N with group size set to 0 and then use the expression "group.split(‘,’) " in the mapper following the Group by N as below. I am getting error and not able to find a way to solve this.
Any help is appreciated.
Thanks
Aravind N
1) First try to split the string by "," - and as an output you will receive array of records:
("AMK,ACK,AGK,ABK").split(',')
output: ["AMK","ACK","AGK","ABK"]
2) Then split the array, using JSON Splitter Snap.
BR,
Spiro Taleski