How to write the activity status to a parameter


  • I need to capture the system variables (Pipeline Name, etc. ) in addition to some other pieces of information about an activity (Status, Name, Rows Read) and pass it from the Copy task to a Stored Procedure task that will write that information to a table in Azure SQL DB.

    Aside from the System Variables how do you access the other pieces (Status, Rows, Activity Name)?  If I select the line connecting the copy task and stored procedure I see a table on the "output" tab with these fields but not sure how to reference them in the stored procedure or store them into parameters?

    Wednesday, June 13, 2018 3:21 PM

All replies

  • Hi Shannon, to reference output of copy activity in store procedure, please use the expression '@activity('Copy activity name').output.fieldname'.

    Reference to see what fieldnames you can use in copy activity output info.

    Thursday, June 14, 2018 1:37 AM
  • This is a good answer, as far as it goes.  What I am finding is that the output properties vary wildly from activity to activity.  For instance, @activity('ActivityName').ExceptionMessage returns the verbose error message for a Lookup activity, but for a Data Copy activity that property does not exist.  @activity('ActivityName').Error returns the verbose error message for that activity type.  For the Stored Procedure activity, I have not yet even found a valid property.  How do we access a valid list of "output" properties for each activity?


    Friday, September 28, 2018 5:22 PM