Forum Discussion
2 Replies
- PrecyNew Contributor
When i tried with below logic i get output as follow:
jsonPath($.mapValues((value, key) => { ALNVALUE: parseFloat(value) || value, ASSETSTTRID:key}), “$*”)
which is not completely correct, i want highlighted assetnum, siteid, classstructureid outside the json path as mentioned in mapper snap.
Seems like i am missing somewhere a bit.
- skatpallyFormer Employee
$.mapValues((value, key) => key==‘IsCritical’ || key==‘maoup’ || key==‘diame’?{AnnalValue:value,ASSETSTTRID:key} : “”).values().filter(x=>x!=“”)
Ignore the field names. Sample_2020_09_02.slp (3.7 KB)