I'm encountering a problem in dotConnect for Oracle 5.0.1.0, which i have also confirmed to be in the latest express edition.
I have the stored procedure:
Code: Select all
TYPE REF_T IS TABLE OF number INDEX BY BINARY_INTEGER;
PROCEDURE TESTPROC(p_list IN REF_T,
p_cursor OUT SYS_REFCURSOR)
I execute it with the following code:
Code: Select all
var count = 65539; //max seems to be 65536 = 2^16
var list = new int[count];
for (var i = 0; i < count; i++)
{
list[i] = i;
}
using (var con = new OracleConnection(conStr))
{
con.Open();
var cmd = con.CreateCommand();
cmd.CommandText = "MYPACKAGE.TESTPROC";
cmd.CommandType = CommandType.StoredProcedure;
var inParm = new OracleParameter("p_list", OracleDbType.Number);
inParm.Value = CreateList();
inParm.Direction = ParameterDirection.Input;
var outParm = new OracleParameter("p_cursor", OracleDbType.Cursor) { Direction = ParameterDirection.Output };
cmd.Parameters.Add(inParm);
cmd.Parameters.Add(outParm);
cmd.ExecuteNonQuery();
var cursor = outParm.Value as OracleCursor;
var dr = cursor.GetDataReader();
var resultList = new List<int>();
while (dr.Read())
{
resultList.Add(dr.GetInt32(0));
}
dr.Close();
}
So it looks like dotConnect has a max list input size of 65535.
If possible, please confirm if this is intended or if it's a bug?
I checked with ODP.NET as well, which always returns the full list using the same example. So the issue seems to be with dotConnect.
Thanks,
Christian