I have a dataflow that has an oledb data source. I then have a script component that performs three web service calls, this has two outputs that are (in effect) synchronous to the input row (one output row per input row), and one output that is asynchronous (outputs many rows for each input row). Each output goes to a sql update command. There is also an error log output (also asynch).
I wish to wrap the outputs in a transaction somehow, so that for each input row, if the row is not completely processed and updated, then none of the updates for that input row succeed.
From what I can tell, the way this works is that the scripts process each input row and output everything to a buffer before moving on to the update commands. I want, instead to perform all updates on a per-row basis, committing changes when each input row has been processed and updated.
How can I structure my dataflow to achieve this?
I'm thinking perhaps of executing the source, then running the records through a foreach container, but i'm unsure of how I would chain multiple DataFlows together that way via a ForEach container.