views:

44

answers:

1

I have a Data Flow Task and am connecting to a database via an OLE DB Source component to extract data. This data feeds into a Conditional Split component to separate the data based on a simple expression.

After the evaluation of this expression, the data will end up in either of two locations: LocationA or LocationB.

Alright, I have that all set up and working properly. Once the data is separated into these two locations, additional processing is to be done on the records.

Here's where I am stuck: I need the the processing of records in LocationA to occur before the processing of records in LocationB.

Is there a way to set precedence of which tasks occur before others? If not, what is the best way to handle this? I was thinking I may need to write the data in LocationA and LocationB back out to the database and create a new data flow task in the control flow to handle the order of which these records must be dealt with.

Any help is greatly appreciated!

A: 

I assume you need the results of LocationA processing for the LocationB processing? I don't have a working implementation of this that I can show you, but conceptually you could do a merge or join of the result of LocationA processing with the input of LocationB, but not actually use the values in the output. This would force LocationA to complete before LocationB runs. alt text

cdonner
You are correct: I need to insert the records of LocationA before the processing of LocationB occurs because I need to use the PrimaryKey of the newly inserted records in LocA to tie the LocB records to. However, I must admit, that your diagram is a bit confusing for me. Would you mind expanding on it just a tad? Thanks for your help so far!
Robert
I updated the diagram. The key is the join condition in the merge join, because you don't want your dataset to change, so it has to be something that is neutral to the input of location b processing.
cdonner

related questions