1

I want to log information using a 2016 SSIS C# (2015) script task that will be easily findable in my SSIS reports I have built. My plan is to use the IDTSComponentEvents.FireInformation method, and use the subcomponent parameter to surface the identifier that I will filter on to only pull these messages. I am able to fire events from my script just fine, but I cannot seem to populate the subcomponent_name column in SSISDB.[catalog].[event_messages]

I can demonstrate with a simple package with a single script task in the control flow. My main method has the following code

public void Main()
    {
        bool fireAgain = true;
        Dts.Events.FireInformation(1, "eventName", "This is a message", "null", 0, ref fireAgain);
        Dts.TaskResult = (int)ScriptResults.Success;        }

If I run this in SSDT I can see my Subcomponent name and my log message: SSDT Log Output

I deploy to SSISDB (I have tried this with our 2016 server, and a 2014 instance) and execute with a Basic log level, and I do not see the subcomponent_name in the standard report, or in ssisdb.[catalog].[event_messages]

SSISDB Log Output

I can filter on the message_source_name for my needs right now easily enough, but it seems odd that this parameter for this method surfaces the sub component name in the SSDT execution results, but not in the SSISDB message log.

How do you populate the Subcomponent Name in an SSISDB message using an SSIS Script task?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.