Forum Stats

  • 3,827,547 Users
  • 2,260,791 Discussions
  • 7,897,297 Comments

Discussions

the return of a procedure that previously worked perfectly with oracle client 12g returns the incomp

User_NKLB5
User_NKLB5 Member Posts: 2 Green Ribbon

Hello, I have an application where I get the CPF by ID in a query via Stored Procedure. The query worked normally, but when I updated to oracle client 19. c* the query result comes in half. Example: 362265 instead of 36226595598


I would like to understand why can someone explain?


What I'm using:


Oracle Client 19.3 C ASP.Net MCV with DotNet Framework 4.8 Oracle.ManagedDataAccess 21.6 Microsoft.Data.OData 5.8 Microsoft.Data.Edm 5.8


The Query is simple and works in other environments:

using (var lCommand = new WebBaseCommand(Nome_procedure, CommandType.StoredProcedure))
        {

            BaseDataAccess.AddDefaultParameters(lCommand);
            BaseDataAccess.SetProcedureVersion(lCommand, 001);

            lCommand.AddInputParameter(USR_ID, OracleType.Number);
            lCommand.SetParameterValue(USR_ID, pUserID);
            lCommand.AddOutputParameter(USR_CPF, OracleType.VarChar, 100);

            lCommand.ExecuteNonQuery();

            if ((decimal)lCommand.GetParameterValue(RETURN_ID) == 1)
            {
                return new UserDocumentResponse
                {
                    Number = lCommand.GetParameterValue<string>(USR_CPF),
                    UserID = userID
                };
            }
            else if (Convert.ToInt32(lCommand.GetParameterValue("P_RESULT")) == -1000)
                throw new DataAccessException(lCommand.GetParameterValue<string>("P_RESULT_MSG"));
            else
                return null;
        }


Tagged:

Answers