ZUGFeRDRESTService: Fix procedure call
This commit is contained in:
parent
f04e1b4c85
commit
33ae746399
@ -192,13 +192,16 @@ namespace ZUGFeRDRESTService.Controllers
|
||||
_logger.Debug("Calling validation prodecure.");
|
||||
try
|
||||
{
|
||||
using SqlCommand oCommand = new SqlCommand("EXEC PRCUST_INV_CHECK_FROM_PORTAL @REF_GUID, @MSG_OUTPUT");
|
||||
oCommand.Parameters.Add("REF_GUID", System.Data.SqlDbType.VarChar, 250).Value = oMessageId;
|
||||
oCommand.Parameters.Add("MSG_OUTPUT", System.Data.SqlDbType.VarChar, 500).Direction = System.Data.ParameterDirection.Output;
|
||||
using SqlCommand oCommand = new SqlCommand("PRCUST_INV_CHECK_FROM_PORTAL");
|
||||
oCommand.CommandType = System.Data.CommandType.StoredProcedure;
|
||||
|
||||
oCommand.Parameters.Clear();
|
||||
oCommand.Parameters.Add("@REF_GUID", System.Data.SqlDbType.VarChar, 250).Value = oMessageId;
|
||||
oCommand.Parameters.Add("@MSG_OUTPUT", System.Data.SqlDbType.VarChar, 500).Direction = System.Data.ParameterDirection.Output;
|
||||
|
||||
if (_database.MSSQL.ExecuteNonQuery(oCommand))
|
||||
{
|
||||
string oReturnValue = (string)oCommand.Parameters["MSG_OUTPUT"].Value;
|
||||
string oReturnValue = (string)oCommand.Parameters["@MSG_OUTPUT"].Value;
|
||||
return new Tuple<bool, string>(true, oReturnValue);
|
||||
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user