Official CozyRoc Blog

July 7, 2008

Data Flow Enumerator Script

Filed under: SSIS — COZYROC @ 2:46 pm

You have probably already seen this scenario. You want to load data, do transformations over it and then enumerate the result data flow in a standard for each loop container. The recommended Microsoft solution is to direct your data flow to in-memory ADO recordset destination component and then setup the for each loop container to iterate the result ADO recordset. As you probably understand this solution has one major shortcoming. It is extremely memory intensive and has unpredictable performance. Wouldn’t be great if somehow the data being processed in a data flow can be send directly for processing in foreach loop enumeration, without intermediate steps requiring additional memory consumption?

Well, thanks to the enhancements our SSIS+ 1.3 library brings, it is now possible to do it. We have created an SSIS script task, which creates wrapper object over standard DataReader Destination component. The object is then stored in package variable and can be used in your enumeration container control flows. The script is available for download here. Enjoy.

Tip: Each iteration item is of type IDataRecord.

Advertisements

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog at WordPress.com.

%d bloggers like this: