public class ben:harrell

September 18, 2007

SSIS Custom Component – ProvideComponentProperties vs ReInitializeMetadata

Filed under: .NET, Custom Source Component, database, Integration Servicees, SQL Server 2005, SSIS, Technology — benjamin harrell @ 9:47 am


I am currently working on a custom source component in SSIS that converts EBCDIC data to ASCII inline and one of the challenges I face is creating dynamic outputs and output columns based on the layout process of the source component.  Normally, when you want to additional outputs on your component you create them in by override ProvideComponentProperties like this:

public override void ProvideComponentProperties()
    // add the outputComponentMetaData.UsesDispositions = true;
   IDTSOutput90 output =     ComponentMetaData.OutputCollection.New();
   output.Name = “My New Output”;
   output.ExternalMetadataColumnCollection.IsUsed = true;

This works really well if all of your output information is available at design time (in the SSIS ui) but what happens if your dynamic outputs are determined at runtime?  ProvideComponentProperties is only called one time, when the component is added to designer surface.  In order to dynamically add outputs at a later point you must use ReInitializeMetaData which is called whenever Validate returns VS_NEEDSNEWMETADATA.

public override void ReinitializeMetaData()
   // add the output
   ComponentMetaData.UsesDispositions = true;
   IDTSOutput90 output = ComponentMetaData.OutputCollection.New();
   output.Name = “My New Output”;
   output.ExternalMetadataColumnCollection.IsUsed = true;

Note that I have not shown the additional work of adding columns to either of these scenarios, you will need to add that code yourself. 



  1. I found this when I randomly was googling old friends names. Looks like you’re doing well (although I have no clue what this all means). Just wanted to say hi.

    Comment by boolie — November 5, 2007 @ 1:56 pm

  2. Just wanted to try and get some more information about Lysine…this is exactly what we’ve been looking for in regards to converting our EBCDIC files in SSIS and dumping them into SQL. When I go to the site, it is just a bit of marketing fluff?!

    Comment by Aaron Corcoran — April 25, 2008 @ 2:56 pm

  3. Can I simply just say what a comfort to find someone who genuinely knows what they are discussing on the net.

    You definitely know how to bring an issue
    to light and make it important. A lot more people must look at this and understand this side of the story.
    I can’t believe you’re not more popular because you surely have the gift.

    Comment by credit cards with low interest rates — July 19, 2013 @ 5:01 am

RSS feed for comments on this post. TrackBack URI

Leave a Reply

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

You are commenting using your 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

Create a free website or blog at

%d bloggers like this: