How do you keep input values provided to tSoap in the next component?

One Star

How do you keep input values provided to tSoap in the next component?

I have a Talend Job that currently does the following:
Input CSV --Main--> tMap --Output--> tSoap --Main--> Output CSV
The input CSV has ID and TYPE as input columns.
The Map creates a Soap XML (String) message using the ID from the CSV and passes that String to the tSoap component.
The tSoap component fires the web request, which sends the response to the next component. That data is then written to CSV.
The problem is that TYPE from the input CSV is not passed through to amalgamate with the SOAP response data. Only the response data seems accessible.
I've had a look at tBufferInput / tBufferOutput and tFlowToIterate but they seem to work in scenarios where the tSoap component does not depend on an input from the main flow.
Does anyone know which components can be used to achieve the amalgamation?
Thank you
Moderator

Re: How do you keep input values provided to tSoap in the next component?

Hi,
Have you tried Context value or global variable in your job? Could you please upload your job setting screenshot?
Best regards
Sabrina
--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.
One Star

Re: How do you keep input values provided to tSoap in the next component?

Thanks - have attached 3 shots
1 - the Job (its more complex than how i've described as i've only described a subset) - the tSoap circled shows the component where I need the values going in to also come back out
2 - the tMap that is underneath tSoap and provides tSoap with its XML to use (and shows how the XML is generated using one of the fields coming into the tMap)
3 - the tSoap component and its schema, showing how the inputs that are needed in the final CSV (along with the tSoap Body) aren't available
One Star

Re: How do you keep input values provided to tSoap in the next component?

Screenshot zips
TalendHelp3.zip.zip
One Star

Re: How do you keep input values provided to tSoap in the next component?

I had exactly the same requirement in the job I have been working on recently.
I resolved it as suggested by Sabrina; before passing my data to the tSoap, I used a tSetGlobalVar to record the information that I wanted to preserve until after the tSoap.  I then used a tMap to bring that data back into the flow.
It's not ideal; it would be nice if tSoap had some pass-through capabilities so that unused values in the "input" schema could be included in the "output" schema.
One Star

Re: How do you keep input values provided to tSoap in the next component?

I had exactly the same requirement in the job I have been working on recently.
I resolved it as suggested by Sabrina; before passing my data to the tSoap, I used a tSetGlobalVar to record the information that I wanted to preserve until after the tSoap.  I then used a tMap to bring that data back into the flow.
It's not ideal; it would be nice if tSoap had some pass-through capabilities so that unused values in the "input" schema could be included in the "output" schema.

Thanks Rocketeer that has worked.
For future users, the Job changed to
tMap --> tSetGlobalVar --> tSoap --> tMap
On the final tMap, to access the variable for the current data row, I used in an output column:
(String)globalMap.get("KEY_AS_SET_IN_tSetGlobalVar");
Thanks again
Tom