Forum Discussion
Thank you so much for your response and the link to the sample pipeline. it seems quite promising . will look into this against our scenario.
in your expression you referenced person
My json does not have a nice header like yours does
How do i add a header or otherwise reference my json array
in
My JSON -
{ID:001, GCUSA:001, GEONAME:United States, YCOORD:37.517544, XCOORD:-92.173105, SEGMNTID:01, SEGNAME:The Wealth Market, Base Count:2813090, %Comp:2.27, NDP_014_C:49484, NDP_014_I:45…}
“ID”: “001”
your JSON-
“person”: {Name:Sam, Month:Jan, Transportation:200, House Rent:1500, Internet:100, Food:500}
Your expression
$person.entries().filter(x => [‘Name’, ‘Month’].indexOf(x[0]) == -1).map(x => { expense: x[0], amount: x[1] })
I want something similar
$??MYJSON??.entries().filter(x=>[‘id’,‘GCUSA’],indexof(x[0] == -1).map(x=>{variable:x[0],values:x[1])
something like that but i dont know how to refer to my JSON array
- rnadgir0018 years agoNew Contributor
I think i got it , Just reference it as $.entries()