Сбой при выполнении хранимой процедуры C#/SQL Server/RepoDB 1.13.1 для выходных параметров ⇐ C#
Сбой при выполнении хранимой процедуры C#/SQL Server/RepoDB 1.13.1 для выходных параметров
I have the following code:
var outputParameter = new SqlParameter { ParameterName = "@ReturnMessage", SqlDbType = SqlDbType.VarChar, // Adjust SqlDbType based on your column type Direction = ParameterDirection.Output, Size = -1 }; var returnValueParameter = new SqlParameter { ParameterName = "@RETURN_VALUE", SqlDbType = SqlDbType.Int, // Adjust SqlDbType based on your column type Direction = ParameterDirection.ReturnValue }; var parameters = new { userName, userId, outputParameter, returnValueParameter}; int data = ExecuteNonQuery("mySP", parameters, commandType: CommandType.StoredProcedure); But, I get this error:
Procedure or function 'mySP' expects parameter '@ReturnMessage', which was not supplied.
How to resolve this RepoDB issue?
Источник: https://stackoverflow.com/questions/781 ... t-paramete
I have the following code:
var outputParameter = new SqlParameter { ParameterName = "@ReturnMessage", SqlDbType = SqlDbType.VarChar, // Adjust SqlDbType based on your column type Direction = ParameterDirection.Output, Size = -1 }; var returnValueParameter = new SqlParameter { ParameterName = "@RETURN_VALUE", SqlDbType = SqlDbType.Int, // Adjust SqlDbType based on your column type Direction = ParameterDirection.ReturnValue }; var parameters = new { userName, userId, outputParameter, returnValueParameter}; int data = ExecuteNonQuery("mySP", parameters, commandType: CommandType.StoredProcedure); But, I get this error:
Procedure or function 'mySP' expects parameter '@ReturnMessage', which was not supplied.
How to resolve this RepoDB issue?
Источник: https://stackoverflow.com/questions/781 ... t-paramete
-
- Похожие темы
- Ответы
- Просмотры
- Последнее сообщение
-
-
Как PHP получает доступ к выходным параметрам хранимой процедуры SQL Server
Anonymous » » в форуме Php - 0 Ответы
- 107 Просмотры
-
Последнее сообщение Anonymous
-