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

Discussion in 'ASP .Net' started by =?Utf-8?B?Sm9vc3QgRXZlcnRzZQ==?=, Nov 5, 2004.

  1. 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;

    ---
    =?Utf-8?B?Sm9vc3QgRXZlcnRzZQ==?=, Nov 5, 2004
    #1
    1. Advertising

  2. "Joost Evertse" <Joost > wrote in message
    news:...
    > 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
    John Saunders, Nov 6, 2004
    #2
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Neil Kimber

    Using Cache object hanging webserver

    Neil Kimber, Jul 21, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    320
    Neil Kimber
    Jul 21, 2003
  2. SK

    odp.net

    SK, Feb 14, 2005, in forum: ASP .Net
    Replies:
    2
    Views:
    677
    Scott Allen
    Feb 14, 2005
  3. venky

    Odp.net

    venky, Feb 15, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    884
    venky
    Feb 15, 2005
  4. Nathan
    Replies:
    0
    Views:
    1,603
    Nathan
    Jan 5, 2006
  5. =?Utf-8?B?RGlmZmlkZW50?=

    ODP.NET and Oracle 10g

    =?Utf-8?B?RGlmZmlkZW50?=, May 1, 2007, in forum: ASP .Net
    Replies:
    1
    Views:
    667
    Cowboy \(Gregory A. Beamer\)
    May 2, 2007
Loading...

Share This Page