Forum Discussion
the_pan_zone
4 years agoNew Contributor
Hi @bojanvelevski ,
Please check the 3rd row in your result set.
Here PAccountName should be ABC instead of “new”. PAccountName should not be the next one it should depend on PAccountID. As PAccountId is same for both 3rd and 4th row so PAccountName should be also same i.e. Abc for both 3rd and 4th Row.
bojanvelevski
4 years agoValued Contributor
Ah, this clarifies things. It was a misunderstanding, the expression you need to use is the following:
$input0.map((x,index)=> x.extend({"PAccountName":$input0.filter(y=>y.AccountID == x.PAccountID)[0].AccountName}))