Hi Rand,
My approach would be to read the two files and store each line in arrays (arr1 and arr2)
Then compare in a function node whether the elements/values of arr1 are included in arr2 and return the missing elements
A combination of Nodes are needed in order for the values to reach the Function node as a single message.
Test Flow :
[{"id":"bde9ac92.1486a8","type":"inject","z":"c95d3cba.8bb268","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":140,"y":100,"wires":[["cee63a33.be22e8"]]},{"id":"cee63a33.be22e8","type":"file in","z":"c95d3cba.8bb268","name":"File1","filename":"/home/pi/Desktop/textone.txt","format":"lines","chunk":false,"sendError":false,"encoding":"none","x":250,"y":200,"wires":[["6e3ab76c.42ae4"]]},{"id":"ac2355eb.4ee788","type":"debug","z":"c95d3cba.8bb268","name":"1","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":730,"y":140,"wires":[]},{"id":"6e3ab76c.42ae4","type":"join","z":"c95d3cba.8bb268","name":"","mode":"custom","build":"array","property":"payload","propertyType":"msg","key":"topic","joiner":"\\n","joinerType":"str","accumulate":false,"timeout":"","count":"","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"num","reduceFixup":"","x":410,"y":200,"wires":[["facf4be6.69a75","cb431c62.669a"]]},{"id":"facf4be6.69a75","type":"file in","z":"c95d3cba.8bb268","name":"File2","filename":"/home/pi/Desktop/texttwo.txt","format":"lines","chunk":false,"sendError":false,"encoding":"none","x":250,"y":340,"wires":[["46c45939.74a4b8"]]},{"id":"46c45939.74a4b8","type":"join","z":"c95d3cba.8bb268","name":"","mode":"custom","build":"array","property":"payload","propertyType":"msg","key":"topic","joiner":"\\n","joinerType":"str","accumulate":false,"timeout":"","count":"","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"num","reduceFixup":"","x":410,"y":340,"wires":[["e72d72aa.5859b8"]]},{"id":"62d5a6e6.02c198","type":"debug","z":"c95d3cba.8bb268","name":"2","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":750,"y":400,"wires":[]},{"id":"cb431c62.669a","type":"change","z":"c95d3cba.8bb268","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.arr1","tot":"msg"},{"t":"set","p":"topic","pt":"msg","to":"arr1","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":600,"y":200,"wires":[["ac2355eb.4ee788","4fe84452.cfcbdc"]]},{"id":"e72d72aa.5859b8","type":"change","z":"c95d3cba.8bb268","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.arr2","tot":"msg"},{"t":"set","p":"topic","pt":"msg","to":"arr2","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":600,"y":340,"wires":[["62d5a6e6.02c198","4fe84452.cfcbdc"]]},{"id":"4fe84452.cfcbdc","type":"join","z":"c95d3cba.8bb268","name":"","mode":"custom","build":"merged","property":"payload","propertyType":"msg","key":"topic","joiner":"\\n","joinerType":"str","accumulate":false,"timeout":"","count":"2","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"num","reduceFixup":"","x":790,"y":260,"wires":[["43d5c154.accb4","30086994.f843ce"]]},{"id":"43d5c154.accb4","type":"debug","z":"c95d3cba.8bb268","name":"3","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":910,"y":220,"wires":[]},{"id":"30086994.f843ce","type":"function","z":"c95d3cba.8bb268","name":"","func":"let arr1 = msg.payload.arr1\nlet arr2 = msg.payload.arr2\nlet missing = []\n\narr1.forEach(el => {\n if (!arr2.includes(el)) missing.push(el)\n\n})\n\nmsg.payload = missing;\n\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":960,"y":320,"wires":[["b825784d.dcceb"]]},{"id":"b825784d.dcceb","type":"debug","z":"c95d3cba.8bb268","name":"4","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":1100,"y":320,"wires":[]}]
PS1. im on a raspberry Pi so the path to your files need to be changed
PS2 in the example im checking file1 values with file2 .. would the reverse be needed ?