Returning a Result Set
A stored procedure may return a result set. In this case you must add columns to the result set row and then add the row to a result set.
This is accomplished as shown below:
SqlSpRow RSrow = NewResultSetRow();
RSrow[RSCol.mycolumn].Value = "";
A stored procedure may also have OUT parameters that must be set before returning. This is enforced by the C# language as the ExecuteSP prototype implements “out” for OUT parameters.
A stored procedure may also have INOUT parameters that may or may not be set before returning. In this case the ExecuteSP prototype implements “ref” for INOUT parameters.
Returning a UDF Result
A user-defined function is declared with a “return” value that is the return value of the ExecuteSP method.