Hey Greene, The LookupRecord as a RecordPath as input. Check out this docs: https://nifi.apache.org/docs/nifi-docs/html/record-path-guide.html#structure <https://nifi.apache.org/docs/nifi-docs/html/record-path-guide.html#structure> or https://www.nifi.rocks/record-path-cheat-sheet/ <https://www.nifi.rocks/record-path-cheat-sheet/>
In your case you could enter /outerrecord/[0]/key. Something like that, I did not test it but you get the idea. Regards Jorge from Datamesh www.dmesh.io > On 24. Mar 2021, at 21:59, Greene (US), Geoffrey N > <geoffrey.n.gre...@boeing.com> wrote: > > Sorry for the resend. Thought I’d try one more time. I’m struggling with > LookupRecord. > > I’m making good progress leaning to use using Lookup Record Processor. > I have it working so that I know how to turn > [{“key”: “value1”}, {“key”:”value2”}, {“key”:”value3”}] > Into > [{“key”: “value1”,”enhanced”:1}, {“key”:”value2”,”enhanced”:2}, > {“key”:”value3”,”enhanced”:3}] > BUT > What if your array is actually inside an outer record? Is that supported? > How? > > What if you have > {“foo”:”bar”, “outerrecord”:[{“key”: “value1”}, {“key”:”value2”}, > {“key”:”value3”}]} > And want to turn it into > {“foo”:”bar”, “outerrecord”:[{“key”: “value1”,”enhanced”:1}, > {“key”:”value2”,”enhanced”:2}, {“key”:”value3”,”enhanced”:3}]} > How do you specify your lookup key is outerrecord/key, but the array of > records is actually located at /outerrecord. Is there some kind of path > magic? Or is there some kind of flow magic where you have to separate > outerrecord into a separate flow file, and then (?somehow?) glue it back in > after its processed? > > (If necessary, I could certainly put the whole thing into an array too, of > course, if that helps.) > > Thanks!