Search code examples
ssisssis-2012

A parameter with type return value is not the first parameter, or there are more than one parameter of type return value


I'm trying to execute a SP with an input parameter and the SP is going to return a value where I need to capture it in a SSIS variable...

I used SQL script task to achieve this, problem is I don't know how to order the the parameter name/ parameter size column...

Below is the screenshot of the SQL script task . enter image description here

Can someone explain me how to use "Parameter name" and "parameter size" in Script task. This the code I'm using:

exec pr_procname ?

I'm using the OLEDB Driver


Solution

  • You need to use code that contains two parameter placeholders:

    EXEC ? = pr_procname ?
    

    and in your parameter mapping the ReturnValue type parameter comes first