Hi. I am getting the this error :
When I compile the script task:
What is missing ? Please help.
Like
4 comments
17:16 Oct 28, 2020
IIRC the DataValueType param expected here isn't an enum. Try changing the code to add this:
var dataValueTypeManager = (DataValueTypeManager)userConnection.AppManagerProvider.GetManager("DataValueTypeManager"); var textDataValueType = (TextDataValueType)dataValueTypeManager.GetInstanceByName("Text");
Then use:
storedProcedure.WithOutputParameter("res_msg", textDataValueType);
Ryan
18:54 Oct 28, 2020
Ryan Farley,
Thanks. Now it runs.
But sorry, I still need some help on recovering the output prm from the stored procedure. It always returns "Core.DB.QueryParameter", instead of the string returned by the SP.
19:06 Oct 28, 2020
Ricardo Bigio,
You can capture that using this:
var resultParameter = (string)storedProcedure.Parameters.FindByName("res_msg").Value;
Ryan
Show all comments