Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
For example, I have a database table with two columns, "ip_address" and "ping_response".. There are 3 rows with ip_address populated, and ping_response is null. The talend job should read the ip addresses with null response, ping them, and record the response. So it goes tdbinput to tflowtoiterate to tsystem to tdboutput. The problem I'm having is capturing the tsystem response and getting it back in the flow in a usable format.
If I choose standard output to normal, it creates a flow, but each line in the tsystem output will result in its own row in the flow, so 3 ip addresses that return 10 lines of ping results will become a 30 rows total.
If I choose standard output to global variable, the tSystem_1_OUTPUT variable will contain the entire ping response, but then the only choice I have to link the tsystem to anything is "run if", not Row->Main or even Trigger->On Component Ok.
It seems no matter what combination I can't get to the full tsystem ping results back into a flow in a usable 1:1 with the ip address. What is the best way to do this?
Hi JasonMiller,
look at the example:
In tSystem choose: Standard output to global variable.
In Command paste: "ping "+((String)globalMap.get("row6.ip"))
In tMap use variables like on a screen.
Save output like you want.
Is this what you want ?
Well that's how I thought it should work, but I can't seem to get it. Can I see your tSystem component tab please?
The only way I can get a main output link from the tSystem component is to choose the Normal type, which doesn't produce tSystem_1_OUTPUT in the globalMap.
Sure, here you go:
And you're not restricted from creating an oubound Main link off of the tSystem component? Obviously not since I see it, but why am I getting this error??
It is just a warning, I think you can ignore it. I don't know why you are getting this warning.
So that's weird.. I set the output to Global Variable, and it won't let me create the Main link.. so I switch it back to Normal and it will let me create the main link and then switch it back to Global Variable, and the main link stays, but it shows the warning. You're right though, it's only a warning and let's me run the job, but there's definitely something funky going on that I can't figure out. It's working though so thank you for the sanity check. I appreciate it.