ODP.NET : VB.NET and PLSQLAssociativeArray, hanging webserver

G

Guest

Hello,

I'm trying to use a PLSQLAssociateiveArray as output parameter using the
examples from the ODP.NET client distribution, but when i call
ExecuteNonQuery(), the webserver hangs.

Regards,
Joost Evertse

Here is the code:

-----
VB.NET code
-----
Try
con.Open()

cmd = New OracleCommand
cmd.CommandText = proc
cmd.CommandType = CommandType.StoredProcedure
cmd.Connection = con

'create the IN parameters using the array given
For i = 0 To paramsin.GetUpperBound(0)
fl.write("parameter: " & paramsin(i, 0) & " waarde: " & paramsin(i, 1))
cmd.Parameters.Add(New OracleParameter(paramsin(i, 0),
OracleDbType.Varchar2, ParameterDirection.Input))
cmd.Parameters(paramsin(i, 0)).Value = paramsin(i, 1)
Next

'create the OUT parameter
Dim oracleparam As OracleParameter = cmd.Parameters.Add("oracleparam",
OracleDbType.Varchar2)

'let's make it a PSQLAssociative Array
oracleparam.CollectionType = OracleCollectionType.PLSQLAssociativeArray

'size the number of array elements, let's say 50
oracleparam.Size() = 50

'create an array of integers, only one 'column', set the size of the field
Dim n(0) As Int32
n(0) = 255
oracleparam.ArrayBindSize = n

'set succes?
Dim m(0) As OracleParameterStatus
m(0) = OracleParameterStatus.Success
oracleparam.ArrayBindStatus = m

'print the parameters that are bound
fl.write("number of parameters : " & cmd.Parameters.Count)

'execute the procedure
cmd.ExecuteNonQuery() 'code hangs here
.....exception handling etc..

---
PLSQL package/procedure---
TYPE gegevensLijst is table of VARCHAR(255) index by binary_integer;
---
procedure getStamGegevens(p_pers_nr IN varchar2, tab_id IN varchar2,
resultaten OUT mutatiejobfiller.gegevensLijst)

is

begin
return;
end getStamGegevens;

---
 
J

John Saunders

Joost Evertse said:
Hello,

I'm trying to use a PLSQLAssociateiveArray as output parameter using the
examples from the ODP.NET client distribution, but when i call
ExecuteNonQuery(), the webserver hangs.

Perhaps you would get more help if you posted this question in
microsoft.public.dotnet.framework.adonet? It doesn't look like it has
anything at all to do with ASP.NET. In particular, you have provided no
reason for us to believe that there would be different behavior if the same
code were executed in a console program.

John Saunders
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top