Microsoft-IIS/8.5 , Oracle output variables are truncated Microsoft-IIS/8.5 , Oracle output variables are truncated oracle oracle

Microsoft-IIS/8.5 , Oracle output variables are truncated


This is the bug in Oracle Client 12c. It truncates not only strings but numbers as well. Reverting to client 11g fixed the problem.


newParam = new    OracleParameter("Response",OracleType.VarChar);Use **OracleType.Char** instead of     **OracleType.VarChar** newParam = new    OracleParameter("Response", OracleType.Char); IT works in my case.

I am using Oracle 11g and VS12 ,truncating output parameter in dot net code, I even changed the output parameter as integer in Stored procedure.

When I changed to Char instead of Varchar as below in dot net it works fine.

db.AddParameter(dbCommand, "p_out_result", OracleType.Char, 300, ParameterDirection.Output, true, 100, 3, null, DataRowVersion.Default, null);


We had the same experiance as you did when migrating to Oracle 12c database (on Oracle servers) and to a Windows 2012 for webservices (IIS 8).

Varchar2 string, returned from a stored procedure, was truncated almost always at half - no mather what setting we used.

Replacing the Oracle client 12 64-bit with client 12 32-bit did NOT solve the problem.

The solution of Vick Rom solved our problem. Oracle client 11 was installed on a 64bit Windows 2012 server.

We are planning to keep it that way until Oracle client 12 won't be fixed.