Well now I have understood what your requirements are. Thank you. Let me ask you know if you have programming skills?
I don't know how the contrib-s7comm node is really working, so I don't know if you have to configure the S7-PLC IP address that it shall send data to in a table or if this node can also receive instructions based on node-red input.msg online. In latter case you are a lucky boy cause then you can write a Node-RED flow sending S7 request to multiple S7 at a time if you know the "unknown" S7.
Here is how I would program it: There is a port scanner for node.js here:
https://github.com/eviltik/evilscan. This scanner can be instructed before called which IP address range it shall scan and which ports. RFC1006 port is 102. After a scan it returns to you the result of the found devices. Then you have a list of available PLCs. To make function calls available you have to include this node.js library into Node-RED (changing settings.js file) like described here
https://nodered.org/docs/writing-functions.html in the chapter "Loading additional modules".
Then Node-RED knowns the evilscan. After that you can use the normal Node-RED function node and write your program and make the library known with the instruction
var evilscan = global.get('evilscan')
Then you can access the function as it is described in the evilscan documentation.
var options = {
target:'127.0.0.1',
port:'21-23',
status:'TROU', // Timeout, Refused, Open, Unreachable
banner:true
};
var scanner = new evilscan(options);
da da da ...
And then you can write your rest of your program