โ07-11-2022 12:51 AM
Hi,
I am trying to change the array to an object and after that only get the value between the ()
Example:
Input
[
{
โSystemsโ : [โArdoq (431)โ, โSnapLogic (780)โ]
}
{
โSystemsโ : [โSnapLogic (780)โ]
}
]
Expected output:
[
{
โSystemsโ : โ431โ,
โSystemsโ : โ780โ
}
{
โSystemsโ : โ780โ
}
]
Pipeline is below with the transformation I already tried with toObjectโฆ
get_valuesFromArray_2022_07_11.slp (6.2 KB)
And I tried also this replace transformation from my last topic: Map expression regex - #6 by JensDeveloper and then change it to โ(โ to extract the character afther the โ(โ
Regards
Jens
Solved! Go to Solution.
โ07-11-2022 02:31 AM
Hi,
Use the below expression in a mapper. After that use the Splitter snap to get the details.
$Systems.map(x => {โSystemsโ : x.substring(x.indexOf(โ(โ)+1, x.indexOf(โ)โ))})
โ07-11-2022 02:31 AM
Hi,
Use the below expression in a mapper. After that use the Splitter snap to get the details.
$Systems.map(x => {โSystemsโ : x.substring(x.indexOf(โ(โ)+1, x.indexOf(โ)โ))})
โ07-11-2022 03:36 AM
Hey @nsingam ,
Thank you for your answer. It works.